PhotoPost Photo Gallery Sales PhotoPost Sales Toll Free Phone Number
Mon-Fri 9am-4pm EST
  PhotoPost Photo Sharing Photo Gallery    Visualize community tm
| | | | | | | | |

Go Back   PhotoPost Community > PhotoPost Support > PhotoPost Classifieds Support > Classifieds How do I...?

Classifieds How do I...? Wondering how to do something in Classifieds?

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
Old October 23rd, 2010, 01:12 PM   #1 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
Where do I find...

Variables... or the html code that prints out the variables...

There's a typo in the code that needs to be fixed. This typo recurs everywhere certain variables are used - mainly variables with links ($buyemail, $toemail, $product, $touserid, $adid). This is just one example.

As you can see from my site's source code for the member's message page:

Code:
Content visible to verified customers only.
A <br /> was cut in half....this results in a /> showing up at the end of several lines. It also causes links on the emails to never end.

I need to know from where this html is generated so it can be fixed. Or where these variables are defined so they can be fixed. Or something.

Thanks!

Last edited by aotc; October 23rd, 2010 at 01:22 PM.
aotc is offline   Reply With Quote
Old October 23rd, 2010, 04:30 PM   #2 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
Not really sure what your trying to say here

where are you having an issue doing what exactly?
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Old October 23rd, 2010, 05:39 PM   #3 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
Certain variables, when they render in html, are rendering with a typo - there's a <BR /> tag that's been broken apart.

Here is an excerpt from how messages are showing up when users check their messages:

smarmyclothes has posted a reply about the following listing:

"I eat you."

I eat you. - AttackoftheCraft Handmade Shop
/>

If you no longer wish to be notified of replies about the above listing, you can disable notification here:

Message - AttackoftheCraft Handmade Shop
/>


The bolded items are the back half of the broken break tag in the code. In my post above, I showed how the source code of the page looks. You can see that right here in bold

com<br">someone

is the first part of that break tag and right here in bold

someone@hotmail.com<br></a> [b]/>[/b

is the second part of the break tag.

That is why I keep getting /> in my messages, and why my emails all come with open ending anchor tags, turning all the text into one giant link.

I need to find out what is creating this html so I can fix this oddity.

I hope that makes sense.
aotc is offline   Reply With Quote
Old October 23rd, 2010, 06:44 PM   #4 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
The code for sending email/msg is in pp-inc.php in the send_ppemail function like this for messaging

Code:
Content visible to verified customers only.
There is no broken tags that I can see here. You can try changing that line above in pp-inc.php to say this and see if that helps you.

Code:
Content visible to verified customers only.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Old October 23rd, 2010, 07:47 PM   #5 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
I tried looking through pp-inc.php. because I saw that comments.php and payment-verification.php (both places where the messsed up letters were being created) called on it to function, but I had no idea where to look. I'll take a look there, thanks!
aotc is offline   Reply With Quote
Old October 24th, 2010, 08:25 AM   #6 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
That line is right in the send_ppemail function.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Old October 25th, 2010, 02:05 PM   #7 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
Changing that line didn't work.

I have been literally chasing this error all day. Let me see if I can make it any more clear where this happening, and hopefully you can point me to the code.

Step One: Somebody leaves a comment on one of my ads.

Step Two: This causes comments.php to generate a message to me telling me someone has left the comment.

Comments.php uses this template to send me the message. Note that there are no broken break tags in this template, so the template is not the problem. The area bolded is where the problem will eventually be...
^User['username'] has posted a comment to the following listing:

"^gettitle"

^Globals['maindir']/showproduct.php?product=^product (this will get a broken break tag piece, />, after it)

If you no longer wish to be notified when comments are posted to the above listing, you can disable notification here:

^Globals['maindir']/comments.php?notify=off&notifyid=^getid&product=^product (this will get a broken break tag piece, />, after it)

Thanks!

The ^Globals['webname'] Team
^Globals['domain']
Comments.php generates the message using the template above in this piece of code:

Code:
Content visible to verified customers only.
It is this line of code, $letter = str_replace("^product","$product",$letter); where the string ^product is replaced by the variable $product that the break tag is being created - whatever is in the variable $product is messed up.

$product is a link to the product that was commented on, and its in this link that there's a piece of a break tag that should not be there. This is what $product looks like when it renders on my member page html:

Code:
Content visible to verified customers only.
Notice the product=18<br" about halfway through the link. That <br is half the broken break tag, and should not be there!

At the end of the product link is the other half of the broken break tag, the /> that keeps showing up in my messages:

product=18<br></a>/><br />

So something about the contents of that $product variable is messed up. And its not just the $product variable, there are several others with the same problem, and they are all variables that contain links. For example, $toemail, $buyemail, $adid, and $buyuserid in payment_verification.php have the same problem.

I'm thinking there's a function that creates these link variables somewhere, like a function in pp-inc.php - like function convert_returns or maybe function construct_newppurl since this is only happening to variables that store links.

Anyhoo, after comments creates the comment and sends me a message about it, I go on to Step Three: I go to check my messages in my member profile area. This causes member.php to be called, and this line of code generates the HTML for the content of my message:

Code:
Content visible to verified customers only.
Step Four: The following HTML is created and rendered on my screen

Code:
Content visible to verified customers only.
Step 5: And I get a message with junk pieces of broken break tags (specifically the /> part) after all active links in my message.
From: aNGrYLiTTLeDeAdGiRL [ October 25 09:10AM ] [ Reply ]

New Comment Posted to comment tester at Attackofthecraft.com

aNGrYLiTTLeDeAdGiRL has posted a comment to the following listing:

"comment tester"

comment tester - AttackoftheCraft Handmade Shop
/> <~~ THERE'S THE BROKEN TAG PIECE

If you no longer wish to be notified when comments are posted to the above listing, you can disable notification here:

Message - AttackoftheCraft Handmade Shop
/> <~~ THERE'S THE BROKEN TAG PIECE


Thanks!
So where is this broken <br /> tag? Whew... I need a nap now.
aotc is offline   Reply With Quote
Old October 25th, 2010, 02:22 PM   #8 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
There is no broken tag. Thats the problem I have looked up and down. Now the email is fine right thats what saying if you select to be emailed?

So really your issue is not with the phrase.

The only place I see break tags is in the line I note about messages but they are not a problem I think.

Here is the phrase thats in the database

Code:
Content visible to verified customers only.
That is the entire phrase. There are no break tags anywhere.

Lets try this

You meantion this line

Code:
Content visible to verified customers only.
what happens if you change it to this

Code:
Content visible to verified customers only.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Old October 25th, 2010, 03:01 PM   #9 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
I changed that line, and there was no difference.

I also uploaded clean versions of pp_inc.php, member.php and comments.php and the stuff is still showing up.
aotc is offline   Reply With Quote
Old October 25th, 2010, 03:11 PM   #10 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
well you can see there is no break tag here in the code try making the line this?

Code:
Content visible to verified customers only.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Old October 25th, 2010, 03:25 PM   #11 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
Ok, that got rid of the junk, but it also removes the anchor tags and turns the links into regular text instead.

Code:
Content visible to verified customers only.
aotc is offline   Reply With Quote
Old October 25th, 2010, 04:36 PM   #12 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
Lets look at this from another angle.

Replace your default files with no edits then make this edit in pp-inc.php and tell me what you get

Code:
Content visible to verified customers only.
change to this

Code:
Content visible to verified customers only.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Old October 25th, 2010, 06:12 PM   #13 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
Nope, that code change didn't change anything.
aotc is offline   Reply With Quote
Old October 25th, 2010, 06:18 PM   #14 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
well what gets me wondering here is why you have an issue its almost like the convert returns function is trying to convert something thats already html which it should not be.

Try making sure your admin options email setting is set to regular email not HTML see if that helps. Seems like your trying to setup html but your not using email just messaging. Maybe a wrong selection of options for what your doing.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Old October 25th, 2010, 07:03 PM   #15 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
Turning off html email had one interesting effect. Every line of the email I received had a <br /> after it. I think this the break tag thats breaking the works...?
aNGrYLiTTLeDeAdGiRL has uploaded one or more listings to a category you subscribe to.<br />
<br />
Image name: <br />
Title: Yep really gonna pull the trigger<br />
Description: <br />
<br />
Link to listing: http://www.attackofthecraft.com/shop/showproduct.php?product=22<br />
<br />
To turn off subscriptions for this category, click on the following link:<br />
<br />
http://www.attackofthecraft.com/shop/misc.php?action=subscribe&sub=3<br />
<br />
The Attackofthecraft.com Team<br />
Attack of the Craft: A Discussion Forum for Indie Craft, DiY, and All Things Handmade - Powered by vBulletin
For now, my workaround is going to be the non-linked url method. It looks good, and they can cut and paste into their browser if need be. We've both put waaaaay too much time and thought into this
aotc is offline   Reply With Quote
Old October 25th, 2010, 07:56 PM   #16 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
I see your link is no longer broken doing that.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Old October 25th, 2010, 08:07 PM   #17 (permalink)
Member
Verified Customer
 
Join Date: Oct 2010
Posts: 68
True... and it would be perfect except for the break tag at the end of every line
aotc is offline   Reply With Quote
Old October 26th, 2010, 09:42 AM   #18 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 71,687
well I will see if there is anything I can do about that. Your generated page is an html page I just wonder why your break tags are not printing as break tags.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is online now   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Where do I find? Charles_cz Photopost Pro How Do I...? 6 April 6th, 2007 07:49 AM
Could not find phrase imported_Ian Bugs - vBulletin 3.5.X 6 July 23rd, 2005 10:53 AM
where can i find.. ncg ReviewPost Installation & Upgrades 4 January 17th, 2005 08:48 PM


All times are GMT -5. The time now is 07:35 PM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0