Welcome to Geeklog, Anonymous Saturday, December 21 2024 @ 11:23 pm EST

Geeklog Forums

Autotags in Signatures


Status: offline

geiss

Forum User
Full Member
Registered: 02/10/04
Posts: 176
Location:Boise, Idaho
I am well versed on Geeklog's stance on allowing html (images in particular) in signatures, and I agree with it totally. HOWEVER... :pray: Would it be possible to allow autotags in signatures? Since autotags link to content already on the GL site, I was thinking it shouldn't be a security issue. A user could upload a sig picture to a media gallery album (moderated if need be for content, image size, dimensions, etc.) and then simply place
Text Formatted Code
    [image:imageidhere]    
in their profile signature box. I've tested the theory, and it doesn't work currently, but is this something that could be done? Can we allow autolinks in signatures? :banana:
Synergy - Stability - Style --- Visit us at glfusion.org
 Quote

Status: offline

Laugh

Site Admin
Admin
Registered: 09/27/05
Posts: 1470
Location:Canada
If you are referring to forum message signatures, this would have to be implemented in the forum plugin itself. The best person to talk to regarding this would be Blaine (the coder of the forum plugin) over at his site, www.portalparts.com.



One of the Geeklog Core Developers.
 Quote

Status: offline

geiss

Forum User
Full Member
Registered: 02/10/04
Posts: 176
Location:Boise, Idaho
cheerful
I've posted a similar thread in Blane's forum, and also in Mark's Media Gallery forum.

I would think though, that it would be more of a core GL request, as the Forum plugin just grabs the signature data from the user's profile. If GL allows the use of autotags in signatures, wouldn't the forum automatically pick up on that? Just my :twocents:

Blaine, Dirk, Mark, any thoughts on this? Feel free to move this thread if it's in the wrong place Big Grin
Synergy - Stability - Style --- Visit us at glfusion.org
 Quote

Status: offline

geiss

Forum User
Full Member
Registered: 02/10/04
Posts: 176
Location:Boise, Idaho
Can anyone shed some light on this? :pray:
Synergy - Stability - Style --- Visit us at glfusion.org
 Quote

Status: offline

jmucchiello

Forum User
Full Member
Registered: 08/29/05
Posts: 985
Sure. It cannot be done with any consistency. There is no function like COM_renderSignature that all code using the signature goes through. Fact is any time the user's signature is printed, it is just read from the database and sent to the browser in code local to whatever decided to print the signature. So in order to make autotags work you need to find all those locations where signatures are printed and include a call to PLG_replaceTags in the flow.

The best you can do is as for a feature request and hope someone creates the COM_renderSig function (and that all the plugin that use signatures switch over to the new function). You can also do this as a bounty to sweeten the deal. The theoretical function described is also the only way sigs can be modified to allow BBCode which is an existing feature request, I think.
 Quote

Status: offline

geiss

Forum User
Full Member
Registered: 02/10/04
Posts: 176
Location:Boise, Idaho
:banana: :banana: :banana:

Mark (Media Gallery author) rocks! He shared some code which does exactly what I need it to do.

http://www.gllabs.org/forum/viewtopic.php?forum=9&showtopic=4452

Many thanks Mark!

Synergy - Stability - Style --- Visit us at glfusion.org
 Quote

Status: offline

Sonjeir

Forum User
Newbie
Registered: 09/26/02
Posts: 3
Would it be possible for you to post the code here the link does not seem to be working.
 Quote

Status: offline

geiss

Forum User
Full Member
Registered: 02/10/04
Posts: 176
Location:Boise, Idaho
This has since become a moot point as Blaine has included Autotag support natively in Forum v2.7, but here is the code for previous versions of Forum.


It actually should be pretty simple to implement, probably just a single call to PLG_replaceTags() for the signature content.

Personally, I think it opens up a whole can of worms since any auto tag would be valid, someone could do some really strange things to a signature.

If it is a must have feature for you on the forums, it is a very simple hack:

edit forum/includes/gf_showtopic.php

somewhere around line 138 you should see:

Text Formatted Code
$sig .= '<B>' .$userarray['sig']. '</B>';
 


Change this line to read:

Text Formatted Code
$sig .= '<B>' .PLG_replaceTags($userarray['sig']). '</B>';
 


Save it and you should be set.

Give this a try and see if it will do what you want.

Thanks!
Mark

Synergy - Stability - Style --- Visit us at glfusion.org
 Quote

Status: offline

Sonjeir

Forum User
Newbie
Registered: 09/26/02
Posts: 3
Having dug around a bit more I noticed the difference in the newest forum plugin code. However thank you very much for your prompt attention to my request.
 Quote

All times are EST. The time is now 11:23 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content