{title} field is overwritten
Posted: 22 February 2008 01:14 PM   [ Ignore ]
Member
RankRankRank
Total Posts:  55
Joined  2007-12-15

First off, thanks to Pie Man, I was able to add lots of features to my site!

Having read the documentation, I understand that variables can clash. I have the entry form in a exp:weblog:entries loop and my photo {title} clashes with the weblog entry title and is overwritten. Is there an alternative to the {title} variable?

{exp:weblog:entries weblog="progress" show_expired="yes" rdf="off" status="open|review" show_future_entries="yes" limit="1"}
Weblog Entry Title
{title}
{exp
:gallery_extended:entries related_id='{segment_3}' type='weblog' disable='member_data|trackbacks'}
<img src='{thumb_url}' alt='{caption}' />
<
p>Title{title} Caption{caption}</p>
{/exp:gallery_extended:entries}
{
/exp:weblog:entries}

Profile
 
 
Posted: 22 February 2008 01:22 PM   [ Ignore ]   [ # 1 ]
Administrator
Avatar
RankRankRankRank
Total Posts:  3232
Joined  2006-10-18

Haha, don’t thank me… I don’t write the software! LOL

Mitchell and Chris are your men! LOL

Try this:

{exp:weblog:entries weblog="progress" show_expired="yes" rdf="off" status="open|review" show_future_entries="yes" limit="1"}
Weblog Entry Title
{title}{/exp:weblog:entries}
{exp
:gallery_extended:entries related_id='{segment_3}' type='weblog' disable='member_data|trackbacks'}
<img src='{thumb_url}' alt='{caption}' />
<
p>Title{title} Caption{caption}</p>
{/exp:gallery_extended:entries}

The Gallery Entries loop should be able to sense the ID from the page anyway smile

By the way, have you grabbed the latest GX2.... it’s the official fixed version smile

 Signature 
Profile
 
 
Posted: 22 February 2008 02:00 PM   [ Ignore ]   [ # 2 ]
Member
RankRankRank
Total Posts:  55
Joined  2007-12-15

Thanks for pointing out the latest version. Just updated.

I already tried the solution you mentioned in your post.

Since I need weblog entry related fields after the exp:gallery_extended entries I have to have two exp:weblog:entries on the same page, e.g.

exp:weblog:entries
exp:gallery_extended
exp:weblog:entries

Is that sequence impacting on performance? Or in other words, having two exp:weblog:entries calls on one page, will that impact performance?
EDIT: Perhaps that’s a question for the Expression Engine folks!

Profile
 
 
Posted: 22 February 2008 02:04 PM   [ Ignore ]   [ # 3 ]
Administrator
Avatar
RankRankRankRank
Total Posts:  3232
Joined  2006-10-18

Yes, it would, but probably not anything noticable. It’s your only way to do it.

If you’d really like to do some testing, try enabling the SQL Queries debugging and Template Debugging:
CP Home › Admin › System Preferences › Output and Debugging Preferences

It’ll show you what’s going on wink

 Signature 
Profile
 
 
Posted: 22 February 2008 02:13 PM   [ Ignore ]   [ # 4 ]
Member
RankRankRank
Total Posts:  55
Joined  2007-12-15

Great! Thanks!

I asked the performance question on the EE forum, let’s see what happens!

http://expressionengine.com/forums/viewthread/72431/

Profile