Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 11 of 11
  1. #1
    Regular Coder
    Join Date
    Mar 2012
    Posts
    158
    Thanks
    21
    Thanked 0 Times in 0 Posts

    Where to put a <p> tag in this?

    Where would I put a paragraph tag in this to have the text show display below the 2 dress pictures at the bottom?
    http://www.themaxidressshop.com/prod...n-maxi-dress-3

    PHP Code:
    <?php
        
    // Setup globals
        // @todo: Get these out of template
        
    global $wp_query;

        
    // Setup image width and height variables
        // @todo: Investigate if these are still needed here
        
    $image_width  get_option'single_view_image_width' );
        
    $image_height get_option'single_view_image_height' );
    ?>

    <div id="single_product_page_container">

        <?php
            
    // Breadcrumbs
            
    wpsc_output_breadcrumbs();

            
    // Plugin hook for adding things to the top of the products page, like the live search
            
    do_action'wpsc_top_of_products_page' );
        
    ?>

        <div class="single_product_display group">
    <?php
            
    /**
             * Start the product loop here.
             * This is single products view, so there should be only one
             */

            
    while ( wpsc_have_products() ) : wpsc_the_product(); ?>
                        <div class="imagecol">
                            <?php if ( wpsc_the_product_thumbnail() ) : ?>
                                    <a rel="<?php echo wpsc_the_product_title(); ?>" class="<?php echo wpsc_the_product_image_link_classes(); ?>" href="<?php echo esc_urlwpsc_the_product_image() ); ?>">
                                        <img class="product_image" id="product_image_<?php echo wpsc_the_product_id(); ?>" alt="<?php echo wpsc_the_product_title(); ?>" title="<?php echo wpsc_the_product_title(); ?>" src="<?php echo wpsc_the_product_thumbnail(); ?>"/>
                                    </a>
                                    <?php
                                    
    if ( function_exists'gold_shpcrt_display_gallery' ) )
                                        echo 
    gold_shpcrt_display_gallerywpsc_the_product_id() );
                                    
    ?>
                            <?php else: ?>
                                        <a href="<?php echo esc_urlwpsc_the_product_permalink() ); ?>">
                                        <img class="no-image" id="product_image_<?php echo wpsc_the_product_id(); ?>" alt="No Image" title="<?php echo wpsc_the_product_title(); ?>" src="<?php echo WPSC_CORE_THEME_URL?>wpsc-images/noimage.png" width="<?php echo get_option('product_image_width'); ?>" height="<?php echo get_option('product_image_height'); ?>" />
                                        </a>
                            <?php endif; ?>
                        </div><!--close imagecol-->

                        <div class="productcol">
                            <?php do_action('wpsc_product_before_description'wpsc_the_product_id(), $wp_query->post); ?>
                            <div class="product_description">
                                <?php echo wpsc_the_product_description(); ?>
                            </div><!--close product_description -->
                            <?php do_action'wpsc_product_addons'wpsc_the_product_id() ); ?>
                            <?php if ( wpsc_the_product_additional_description() ) : ?>
                                <div class="single_additional_description">
                                    <p><?php echo wpsc_the_product_additional_description(); ?></p>
                                </div><!--close single_additional_description-->
                            <?php endif; ?>
                            <?php do_action'wpsc_product_addon_after_descr'wpsc_the_product_id() ); ?>
                            <?php
                            
    /**
                             * Custom meta HTML and loop
                             */
                            
    ?>
                            <?php if (wpsc_have_custom_meta()) : ?>
                            <div class="custom_meta">
                                <?php while ( wpsc_have_custom_meta() ) : wpsc_the_custom_meta(); ?>
                                    <?php if (stripos(wpsc_custom_meta_name(),'g:') !== FALSE) continue; ?>
                                    <strong><?php echo wpsc_custom_meta_name(); ?>: </strong><?php echo wpsc_custom_meta_value(); ?><br />
                                <?php endwhile; ?>
                            </div><!--close custom_meta-->
                            <?php endif; ?>
                            <?php
                            
    /**
                             * Form data
                             */
                            
    ?>
                            <form class="product_form" enctype="multipart/form-data" action="<?php echo esc_urlwpsc_this_page_url() ); ?>" method="post" name="1" id="product_<?php echo wpsc_the_product_id(); ?>">
                                <?php do_action 'wpsc_product_form_fields_begin' ); ?>
                                <?php if ( wpsc_product_has_personal_text() ) : ?>
                                    <fieldset class="custom_text">
                                        <legend><?php _e'Personalize Your Product''wpsc' ); ?></legend>
                                        <p><?php _e'Complete this form to include a personalized message with your purchase.''wpsc' ); ?></p>
                                        <textarea cols='55' rows='5' name="custom_text"></textarea>
                                    </fieldset>
                                <?php endif; ?>

                                <?php if ( wpsc_product_has_supplied_file() ) : ?>

                                    <fieldset class="custom_file">
                                        <legend><?php _e'Upload a File''wpsc' ); ?></legend>
                                        <p><?php _e'Select a file from your computer to include with this purchase.''wpsc' ); ?></p>
                                        <input type="file" name="custom_file" />
                                    </fieldset>
                                <?php endif; ?>
                            <?php /** the variation group HTML and loop */?>
                            <?php if (wpsc_have_variation_groups()) { ?>
                            <fieldset><legend><?php _e('Product Options''wpsc'); ?></legend>
                            <div class="wpsc_variation_forms">
                                <table>
                                <?php while (wpsc_have_variation_groups()) : wpsc_the_variation_group(); ?>
                                    <tr><td class="col1"><label for="<?php echo wpsc_vargrp_form_id(); ?>"><?php echo wpsc_the_vargrp_name(); ?>:</label></td>
                                    <?php /** the variation HTML and loop */?>
                                    <td class="col2"><select class="wpsc_select_variation" name="variation[<?php echo wpsc_vargrp_id(); ?>]" id="<?php echo wpsc_vargrp_form_id(); ?>">
                                    <?php while (wpsc_have_variations()) : wpsc_the_variation(); ?>
                                        <option value="<?php echo wpsc_the_variation_id(); ?><?php echo wpsc_the_variation_out_of_stock(); ?>><?php echo wpsc_the_variation_name(); ?></option>
                                    <?php endwhile; ?>
                                    </select></td></tr>
                                <?php endwhile; ?>
                                </table>
                            </div><!--close wpsc_variation_forms-->
                            </fieldset>
                            <?php ?>
                            <?php /** the variation group HTML and loop ends here */?>

                                <?php
                                
    /**
                                 * Quantity options - MUST be enabled in Admin Settings
                                 */
                                
    ?>
                                <?php if(wpsc_has_multi_adding()): ?>
                                    <fieldset><legend><?php _e('Quantity''wpsc'); ?></legend>
                                    <div class="wpsc_quantity_update">
                                    <input type="text" id="wpsc_quantity_update_<?php echo wpsc_the_product_id(); ?>" name="wpsc_quantity_update" size="2" value="1" />
                                    <input type="hidden" name="key" value="<?php echo wpsc_the_cart_item_key(); ?>"/>
                                    <input type="hidden" name="wpsc_update_quantity" value="true" />
                                    </div><!--close wpsc_quantity_update-->
                                    </fieldset>
                                <?php endif ;?>
                                <div class="wpsc_product_price">
                                    <?php if(wpsc_show_stock_availability()): ?>
                                        <?php if(wpsc_product_has_stock()) : ?>
                                            <div id="stock_display_<?php echo wpsc_the_product_id(); ?>" class="in_stock"><?php _e('Product in stock''wpsc'); ?></div>
                                        <?php else: ?>
                                            <div id="stock_display_<?php echo wpsc_the_product_id(); ?>" class="out_of_stock"><?php _e('Product not in stock''wpsc'); ?></div>
                                        <?php endif; ?>
                                    <?php endif; ?>
                                    <?php if(wpsc_product_is_donation()) : ?>
                                        <label for="donation_price_<?php echo wpsc_the_product_id(); ?>"><?php _e('Donation''wpsc'); ?>: </label>
                                        <input type="text" id="donation_price_<?php echo wpsc_the_product_id(); ?>" name="donation_price" value="<?php echo wpsc_calculate_price(wpsc_the_product_id()); ?>" size="6" />
                                    <?php else : ?>
                                        <?php wpsc_the_product_price_display(); ?>
                                         <!-- multi currency code -->
                                        <?php if(wpsc_product_has_multicurrency()) : ?>
                                            <?php echo wpsc_display_product_multicurrency(); ?>
                                        <?php endif; ?>
                                        <?php if(wpsc_show_pnp()) : ?>
                                            <p class="pricedisplay"><?php _e('Shipping''wpsc'); ?>:<span class="pp_price"><?php echo wpsc_product_postage_and_packaging(); ?></span></p>
                                        <?php endif; ?>
                                    <?php endif; ?>
                                </div><!--close wpsc_product_price-->

                                <!-- ShareThis -->
                                <?php if ( get_option'wpsc_share_this' ) == ): ?>
                                <div class="st_sharethis" displayText="ShareThis"></div>
                                <?php endif; ?>
                                <!-- End ShareThis -->

                                <input type="hidden" value="add_to_cart" name="wpsc_ajax_action" />
                                <input type="hidden" value="<?php echo wpsc_the_product_id(); ?>" name="product_id" />
                                <?php if( wpsc_product_is_customisable() ) : ?>
                                    <input type="hidden" value="true" name="is_customisable"/>
                                <?php endif; ?>

                                <?php
                                
    /**
                                 * Cart Options
                                 */
                                
    ?>

                                <?php if((get_option('hide_addtocart_button') == 0) &&  (get_option('addtocart_or_buynow') !='1')) : ?>
                                    <?php if(wpsc_product_has_stock()) : ?>
                                        <div class="wpsc_buy_button_container">
                                                <?php if(wpsc_product_external_link(wpsc_the_product_id()) != '') : ?>
                                                <?php $action wpsc_product_external_linkwpsc_the_product_id() ); ?>
                                                <input class="wpsc_buy_button" type="submit" value="<?php echo wpsc_product_external_link_textwpsc_the_product_id(), __'Buy Now''wpsc' ) ); ?>" onclick="return gotoexternallink('<?php echo esc_url$action ); ?>', '<?php echo wpsc_product_external_link_targetwpsc_the_product_id() ); ?>')">
                                                <?php else: ?>
                                            <input type="submit" value="<?php _e('Add To Cart''wpsc'); ?>" name="Buy" class="wpsc_buy_button" id="product_<?php echo wpsc_the_product_id(); ?>_submit_button"/>
                                                <?php endif; ?>
                                            <div class="wpsc_loading_animation">
                                                <img title="Loading" alt="Loading" src="<?php echo wpsc_loading_animation_url(); ?>" />
                                                <?php _e('Updating cart...''wpsc'); ?>
                                            </div><!--close wpsc_loading_animation-->
                                        </div><!--close wpsc_buy_button_container-->

                                    <?php else : ?>
                                        <p class="soldout"><?php _e('This product has sold out.''wpsc'); ?></p>
                                    <?php endif ; ?>
                                <?php endif ; ?>
                                <?php do_action 'wpsc_product_form_fields_end' ); ?>
                            </form><!--close product_form-->

                            <?php
                                
    if ( (get_option'hide_addtocart_button' ) == ) && ( get_option'addtocart_or_buynow' ) == '1' ) )
                                    echo 
    wpsc_buy_now_buttonwpsc_the_product_id() );

                                echo 
    wpsc_product_rater();

                                echo 
    wpsc_also_boughtwpsc_the_product_id() );

                            if(
    wpsc_show_fb_like()): ?>
                                <div class="FB_like">
                                <iframe src="https://www.facebook.com/plugins/like.php?href=<?php echo wpsc_the_product_permalink(); ?>&amp;layout=standard&amp;show_faces=true&amp;width=435&amp;action=like&amp;font=arial&amp;colorscheme=light" frameborder="0"></iframe>
                                </div><!--close FB_like-->
                            <?php endif; ?>
                        </div><!--close productcol-->
                        <form onsubmit="submitform(this);return false;" action="<?php echo esc_urlwpsc_this_page_url() ); ?>" method="post" name="product_<?php echo wpsc_the_product_id(); ?>" id="product_extra_<?php echo wpsc_the_product_id(); ?>">
                            <input type="hidden" value="<?php echo wpsc_the_product_id(); ?>" name="prodid"/>
                            <input type="hidden" value="<?php echo wpsc_the_product_id(); ?>" name="item"/>
                        </form>
            </div><!--close single_product_display-->

            <?php echo wpsc_product_comments(); ?>

    <?php endwhile;

        
    do_action'wpsc_theme_footer' ); ?>

    </div><!--close single_product_page_container-->

  • #2
    Senior Coder
    Join Date
    Sep 2010
    Posts
    2,246
    Thanks
    15
    Thanked 254 Times in 254 Posts
    There's already one there. Open the page in Firefox, only Firefox lets you do this, then right click and go 'Select all, than again and do "View selection source', then find 'Stunning and simple' and you will see it. But you have to find it in the .css to change its style.
    Welcome to http://www.myphotowizard.net

    where you can edit images, make a photo calendar, add text to images, and do much more.


    When you know what you're doing it's called Engineering, when you don't know, it's called Research and Development. And you can always charge more for Research and Development.

  • #3
    Master Coder felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    6,642
    Thanks
    0
    Thanked 649 Times in 639 Posts
    Quote Originally Posted by DrDOS View Post
    There's already one there. Open the page in Firefox, only Firefox lets you do this, then right click and go 'Select all, than again and do "View selection source', then find 'Stunning and simple' and you will see it. But you have to find it in the .css to change its style.
    In any browser other than Firefox just view source or if you need to see how the browser interprets the HTML then open the built in developer tools.
    Stephen
    Learn Modern JavaScript - http://javascriptexample.net/
    Helping others to solve their computer problem at http://www.felgall.com/

    Don't forget to start your JavaScript code with "use strict"; which makes it easier to find errors in your code.

  • #4
    Senior Coder
    Join Date
    Sep 2010
    Posts
    2,246
    Thanks
    15
    Thanked 254 Times in 254 Posts
    Quote Originally Posted by felgall View Post
    In any browser other than Firefox just view source or if you need to see how the browser interprets the HTML then open the built in developer tools.
    Other browsers will not show you the javascript build on the page, they will only show the 'bare' source. It's a very handy feature, I use it all the time, try it, believe me, you will like it.

    For instance, you can see if data hs been properly entered into hidden form fields, or img tags have their proper source. Any change that JS has made can be seen.
    Welcome to http://www.myphotowizard.net

    where you can edit images, make a photo calendar, add text to images, and do much more.


    When you know what you're doing it's called Engineering, when you don't know, it's called Research and Development. And you can always charge more for Research and Development.

  • #5
    Regular Coder
    Join Date
    Mar 2012
    Posts
    158
    Thanks
    21
    Thanked 0 Times in 0 Posts
    The "stunning and simple" is the default product description stop. I am looking to add text below the 2 smaller pictures below the main bigger picture. Is there a way to tell the .php page that is being pulled in here? I thought it would be wpsc-single_product.php but is there a way to tell using firebug?

    In that file you see an imagecol class which is the big and little pictures div, so I though adding a div or p below that would do it but maybe I am in the wrong spot...

  • #6
    Master Coder felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    6,642
    Thanks
    0
    Thanked 649 Times in 639 Posts
    Quote Originally Posted by DrDOS View Post
    Other browsers will not show you the javascript build on the page, they will only show the 'bare' source.
    All browsers except Firefox will show you everything in the web page the way the browser has interpreted it (including all the JavaScript) if you go into the Developer Tools. You can even have it step through any JavaScript one statement at a time and examine all the values.

    Internet Explorer and Chrome - press F12.
    Opera - press CTRL-Shift-I.

    Firefox is the only popular browser that doesn't have proper developer tools built in and relies on extensions instead to add the functionality provided native in other browsers.
    Stephen
    Learn Modern JavaScript - http://javascriptexample.net/
    Helping others to solve their computer problem at http://www.felgall.com/

    Don't forget to start your JavaScript code with "use strict"; which makes it easier to find errors in your code.

  • #7
    Senior Coder
    Join Date
    Sep 2010
    Posts
    2,246
    Thanks
    15
    Thanked 254 Times in 254 Posts
    Quote Originally Posted by felgall View Post
    All browsers except Firefox will show you everything in the web page the way the browser has interpreted it (including all the JavaScript) if you go into the Developer Tools. You can even have it step through any JavaScript one statement at a time and examine all the values.

    Internet Explorer and Chrome - press F12.
    Opera - press CTRL-Shift-I.

    Firefox is the only popular browser that doesn't have proper developer tools built in and relies on extensions instead to add the functionality provided native in other browsers.
    Well, sorry about that, it's nice to know about, I have used that feature before but did not know it could do all those things, and I still like the Firefox way because I can see the entire page source in fullscreen. And thank you for that information.
    Welcome to http://www.myphotowizard.net

    where you can edit images, make a photo calendar, add text to images, and do much more.


    When you know what you're doing it's called Engineering, when you don't know, it's called Research and Development. And you can always charge more for Research and Development.

  • #8
    Regular Coder
    Join Date
    Mar 2012
    Posts
    158
    Thanks
    21
    Thanked 0 Times in 0 Posts
    Any idea on my question 3 posts up?

  • #9
    Master Coder felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    6,642
    Thanks
    0
    Thanked 649 Times in 639 Posts
    The two images are defined in a <div> just above the line that reads:

    </div><!--close imagecol-->

    The code for those images is actually in the code you posted at the top of the thread.It isn't referencing a different file, you have already found the right one with that post.

    Since all of the PHP runs on the server and only delivers the final HTML to the browser there is no way to tell using any browser tools as to which file particular content was included from. It just happens that the file you are looking for that displays the two images is the one you posted at the start of the thread.
    Stephen
    Learn Modern JavaScript - http://javascriptexample.net/
    Helping others to solve their computer problem at http://www.felgall.com/

    Don't forget to start your JavaScript code with "use strict"; which makes it easier to find errors in your code.

  • #10
    Regular Coder
    Join Date
    Mar 2012
    Posts
    158
    Thanks
    21
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by felgall View Post
    The two images are defined in a <div> just above the line that reads:

    </div><!--close imagecol-->

    The code for those images is actually in the code you posted at the top of the thread.It isn't referencing a different file, you have already found the right one with that post.

    Since all of the PHP runs on the server and only delivers the final HTML to the browser there is no way to tell using any browser tools as to which file particular content was included from. It just happens that the file you are looking for that displays the two images is the one you posted at the start of the thread.
    Thats what I thought. So I inserted my paragraph (below) but nothing shows up and the source code has no record of it when using Firebug.. Which is why I thought maybe I was in the wrong file for some reason. Any idea?!?

    Code:
    					</div><!--close imagecol-->
    	  <p>Please keep in mind that due to differences in computer monitors, colors may differ slightly from the picture. They are even better in person!</p>
    					<div class="productcol">

  • #11
    Master Coder felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    6,642
    Thanks
    0
    Thanked 649 Times in 639 Posts
    Try it above that </div> line instead of below it.
    Stephen
    Learn Modern JavaScript - http://javascriptexample.net/
    Helping others to solve their computer problem at http://www.felgall.com/

    Don't forget to start your JavaScript code with "use strict"; which makes it easier to find errors in your code.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •