deadend Posted March 22, 2013 Share Posted March 22, 2013 Hi, The following code shows a short description that is entered for the product. Since i have alot of products, and want to use the short description as a notice, i would like it to show only some text i.e. "This is custom text for field". if (!empty($this->product->product_s_desc)) { ?> <div class="product-short-description"> <?php I tryed alot of things but allways show a server error. echo "This is custom text for field"; Thank you in advance. Quote Link to comment Share on other sites More sharing options...
DaveyK Posted March 22, 2013 Share Posted March 22, 2013 Do you have error reporting turned on? If not, turn it on: error_reporting(E_ALL); ini_set("display_errors", 1); Quote Link to comment Share on other sites More sharing options...
deadend Posted March 22, 2013 Author Share Posted March 22, 2013 (edited) Hi, Thank you for the quick response. My mistake in the first post, i did not copy the full code for that part: // Product Short Description if (!empty($this->product->product_s_desc)) { ?> <div class="product-short-description"> <?php /** @todo Test if content plugins modify the product description */ echo nl2br($this->product->product_s_desc); ?> </div> <?php } // Product Short Description END I don't know what to write so that allways shows my text line instead of $this->product->product_s_desc Thank you. Edited March 22, 2013 by deadend Quote Link to comment Share on other sites More sharing options...
Jessica Posted March 22, 2013 Share Posted March 22, 2013 (edited) Remove the entire section you've shown us...And put in your text. Edited March 22, 2013 by Jessica Quote Link to comment Share on other sites More sharing options...
DaveyK Posted March 22, 2013 Share Posted March 22, 2013 Also, you say you are getting a 500 error (server error). What I want to know, is if you show errors? Do you have error reporting turned on? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.