WordPress.org

Ready to get started?Download WordPress

Forums

php shortcode changes page format (8 posts)

  1. mcasan0va
    Member
    Posted 2 years ago #

    Hi, When i add the price table php shortcode <?php echo do_shortcode('[ahm-pricing-table id=615]');?> to index.php , everything in the body shifts itself to the left and the text size seems to increase. Is there a way to add the php shortcode without the page format changing?? Is there a code i can use to isolate the shortcode or something? I am TOTALLY new at this. thanks
    look: egraphix.net
    but when i take the shortcode out everything goes back to the center like it should be. thanks again

  2. davidsword
    Member
    Posted 2 years ago #

    you shouldn't use <center> for valid html.. especially to center <div>'s ..

    It may be that you just need a wrapper to center it. do something similar to:

    <div style='width:960px;margin:0px auto;overflow:hidden'>
    <?php echo do_shortcode('[ahm-pricing-table id=615]');?>
    </div>

    but note you got a many big html errors that should be tended to: http://validator.w3.org/check?uri=http%3A%2F%2Fegraphix.net%2F&charset=%28detect+automatically%29&doctype=Inline&group=0

  3. mcasan0va
    Member
    Posted 2 years ago #

    It didn't work :/ but thanks a lot for your response..I guess ill have to keep trying.. And i will definitely look over those even if i dont know what they mean lol..

  4. alchymyth
    The Sweeper & Moderator
    Posted 2 years ago #

    what code is used within the shortcode (is it from a plugin? and if, what is the download-link of the plugin?)

    is the shortcode active in your site right now?

    (I couldn't see any price table in your linked page)

  5. mcasan0va
    Member
    Posted 2 years ago #

    I put it there now. Yes its from a plugin Pricing table Version 1.0.6 by Shaon http://shaon.info/pricing-table-pricing-table-builder-plugin-for-wordpress/

    everything looks fine if i take the code out..

    thanks

  6. mcasan0va
    Member
    Posted 2 years ago #

    http://wordpress.org/support/topic/php-shortcode-messes-up-formatting-a-fix?replies=2

    I think this describes my problem but it didnt work for me..

  7. alchymyth
    The Sweeper & Moderator
    Posted 2 years ago #

    the plugin seems to be broken; even the plugin demo has severe validation errors http://validator.w3.org/check?uri=http%3A%2F%2Fshaon.info%2Fwordpress-pricing-table%2F&charset=%28detect+automatically%29&doctype=Inline&group=0

    (unmatched opening/closing divs)

    possibly try to contact the plugin author and check if they have a fix

  8. mcasan0va
    Member
    Posted 2 years ago #

    Ok thanks for your help!

Topic Closed

This topic has been closed to new replies.

About this Topic