Viewing 15 replies - 1 through 15 (of 18 total)
  • Plugin Author AccountClosed

    (@wistudatbe)

    Hi Manux_oS,

    In practical terms this can be done with the following code:

    echo do_shortcode('[gridwud slug="your-slug"]');

    Just see that you include this inside a <div> to avoid lay-out problems:

    <div style="width:xxx; ... ; ...">
    echo do_shortcode('[gridwud slug="your-slug"]');
    </div>

    Let me know the results!
    Regards, Danny

    Plugin Author AccountClosed

    (@wistudatbe)

    This is a better sample:

    if (function_exists('grid_wud_funcs')) {
    	echo '<div style="type-here-css-values">';
    		echo do_shortcode('[gridwud slug="type-here-your-slug"]');
    	echo '</div>';
    }

    This will check or Grid WUD is active and if yes it displays the grids.
    Change : “type-here-css-values” in real CSS values.
    Change : “type-here-your-slug” in a real slug.

    If you disable the Grid WUD plugin, it will not be displayed.

    Regards, Danny

    Thread Starter Manux_oS

    (@manux_os)

    Thanks for your support,

    For a start i tried the following:

    <div class="wud">
    <?php echo do_shortcode('[gridwud slug="smartphone" button="1"]'); ?>
    </div>

    Worked nice! You can check here: TechValue.gr

    Is there any way to control the height?

    .wud {
    clear: both;
    margin: auto;
    max-width: 960px;
    padding-top: 10px;
    text-align: center;
    }

    Thanks ??

    Thread Starter Manux_oS

    (@manux_os)

    I took a screenshot for you to check your cool plugin in action:

    https://techvalue.gr/wp-content/uploads/2016/08/wud.jpg

    I had to remove the code, it’s a live site.

    Plugin Author AccountClosed

    (@wistudatbe)

    Hi Manux_oS,
    If you can provide me an URL from a page/post where i can see Grid WUD in action, i can help you with your height question.
    Regards, Danny

    Thread Starter Manux_oS

    (@manux_os)

    Thanks so much Danny,

    You can have a look now. TechValue.gr

    Let me know if you need any help testing etc

    Plugin Author AccountClosed

    (@wistudatbe)

    Your welcome Manux_oS,, but can you provide me an URL where Grid WUD is in action?
    On your front page is nothing to see with Grid WUD.
    Regards, Danny

    Thread Starter Manux_oS

    (@manux_os)

    Sorry Danny, had to disable it again for some time, you can have a look now.

    https://techvalue.gr/

    Clean your cache if you don’t see it.

    Thanks

    Thread Starter Manux_oS

    (@manux_os)

    It’s ok i managed to control the height.

    Thanks for your time

    Plugin Author AccountClosed

    (@wistudatbe)

    Hi Manos,
    I’ve seen now the grids on top of your page and it looks great!
    Your site rocks ??
    Regards, Danny

    Thread Starter Manux_oS

    (@manux_os)

    Hey Danny,

    Thanks ??

    It’s not done yet ?? I will need your support again! I have also complete the contact form in your website!

    Thread Starter Manux_oS

    (@manux_os)

    Here is my code if someone wants to show it only at home page:

    <div class="wud">
    <?php if( is_front_page())	: ?>
    <?php echo do_shortcode('[gridwud slug="smartphone" button="1"]'); ?>
    <?php endif;?>
    </div>
    Plugin Author AccountClosed

    (@wistudatbe)

    Hey Manos,

    The contact form we are using is: Clean and Simple Contact Form.
    And the security is reCAPTCHA from Google.
    For those who want to see this in action, click HERE
    .
    Regards, Danny

    Plugin Author AccountClosed

    (@wistudatbe)

    Hey Manos,
    Your code seems to be oké ??
    You can simplify it like this:

    <div class="wud">
    <?php
     if( is_front_page() || ishome())	:
     echo do_shortcode('[gridwud slug="smartphone" button="1"]');
     endif;
    ?>
    </div>

    I have added the ishome() check.

    is_front_page() returns true if the user is on the page or page of posts that is set to the front page on Settings->Reading->Front page displays

    is_home() return true when on the posts list page, This is usually the page that shows the latest 10 posts.

    (explained here)

    And for NOW … i go to start and enjoy my weekend ??

    Regards, Danny

    Thread Starter Manux_oS

    (@manux_os)

    Thanks Danny, for sure you have to go and enjoy the weekend!

Viewing 15 replies - 1 through 15 (of 18 total)
  • The topic ‘Insert in php?’ is closed to new replies.