Sara (waterofthemoon) wrote in component_help,

  • Mood:

Tags related, sort of

Ok, so I've customized my entries to have the edit/memory buttons under the userpic instead of beside it. This is no big deal, as I have used this code successfully in four or five previous layouts.

My issue now is wanting to add the new tags button to this group. I tried a variation of what was used on the others, but it doesn't work for some reason; I get an "Unknown local variable" error on $edittags.

This is my code, with the offending section in bold:

var Link editlink = $e->get_link("edit_entry");
if (defined $editlink and $editlink.url!="") { """<a href="$editlink.url"><img src="" alt="edit entry"></a>"""; }

var Link tagslink = $e->get_link("edit_tags");
if (defined $tagslink and $tagslink.url!="") { """<a href="$edittags.url"><img src="" alt="edit tags"></a>"""; }

var Link memlink = $e->get_link("mem_add");
if (defined $memlink and $memlink.url!="") { """<a href="$memlink.url"><img src="" alt="add to memories"></a>"""; }

Anyone have any ideas? Sorry if this has been posted before... I did look, I promise. :-)

EDIT: Um, yeah. Me = first class idiot who doesn't pay attention to her variables. For the record, $edittags.url should have been $tagslink.url, the same name as every other reference to that variable in the statement. :-\ Fixed, and hopefully this post will be good for helping someone else.

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened