The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

[resolved] how to use get_option function? (3 posts)

  1. Spyroweb
    Posted 2 years ago #

    i have crate a menu under setting then i create two fields there

    1. slide width
    2. slide height

    my slide width id is width
    my slide height id is height

    now i want to get these value which i have saved in the above two.

    i try <?php echo get_option('height');?>

    but its give me an empty value.

    any one which have idea about this.

    i think i am passing wrong value in get_option

    height is my id of slide height.

  2. Bart Dabek
    Posted 2 years ago #

    look in your wp_options table to see what the value is saved as... it might be being saved as slide_width and slide_height ... so when you get 'height' it doesn't exist

  3. Spyroweb
    Posted 2 years ago #


    this was not my problem.

    i have solved it.

    <?php $options = get_option( 'spyro_slider_settings' );?>
    <?php echo $option['height'];?>

Topic Closed

This topic has been closed to new replies.

About this Topic