Cyclone Slider
List of gallery ids (2 posts)

  1. miguelsaddress
    Posted 2 years ago #

    Hello, nice plugin.
    Im authoring a plugin to insert a tinyMCE button in the editor which is displaying a select box to choose an existing cycloneslider gallery ... but I am not able to make a query to select the existing gallery ids...

    any help?

    thank you so much in advance!


  2. miguelsaddress
    Posted 2 years ago #


    My brain had a bad day yesterday ^_^I found out by myself what i wanted, so i post it:

    $sql = "SELECT distinct post_name FROM {$wpdb->posts} WHERE ID IN (
    		SELECT distinct post_id FROM {$wpdb->postmeta} WHERE meta_key = '_cycloneslider_settings' ORDER BY post_id
    	$rows = $wpdb->get_results( $sql );
    	$opt = "<select id='tinymce-slider-id_select'>";
    	$opt .= "<option value='none'>-- Selecciona --</option>";
    	foreach ($rows as $r) {
    		$opt .= "<option value='{$r->post_name}'>{$r->post_name}</option>";
    	$opt .= "</select>";

    Just in case it helps someone :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Cyclone Slider
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic