Jump to content

Photo
- - - - -

@, hashtag basic


  • Please log in to reply
6 replies to this topic

#1 angeldelamuertex

angeldelamuertex

    Level 4

  • Banned
  • Level
  • 69 points
  • 181 posts
    • Gender:Not Telling
    • Software:SE 3.1x

Posted 08 October 2013 - 05:11 AM

create in include/smarty/plugin/modifier.hasta.php
and paste:

<?php
/**
* twitterStatusUrlConverter
* To convert links on a twitter status to a clickable url. Also convert @ to follow link, and # to search
* @author: Mardix - http://mardix.wordpress.com, http://www.givemebeats.net
* @date: March 16 2009
* @license: LGPL (I don't care, it's free lol)
* @param string : the status
* @param bool : true|false, allow target _blank
* @param int : to truncate a link to max length
* @return String
* */
function smarty_modifier_hashtag($message,$targetBlank=true,$linkMaxLen=250){
// The target
$target=$targetBlank ? " target=\"_blank\" " : "";
// convert link to url
$message = preg_replace("/((http:\/\/|https:\/\/)[^ )]+)/e", "'<a href=\"$1\" title=\"$1\" $target >'. ((strlen('$1')>=$linkMaxLen ? substr('$1',0,$linkMaxLen).'...':'$1')).'</a>'", $message);
// convert @ to follow
$message = preg_replace("/(@([_a-z0-9\-]+))/i","<a href=\"http://twitter.com/$2\" title=\"Follow $2\" $target >$1</a>",$message);
// convert # to search
$message = preg_replace("/(#([_a-z0-9\-]+))/i","<a href=\"http://search.twitter.com/search?q=%23$2\" title=\"Search $1\" $target >$1</a>",$message);
// return the status
return $message;
}
?>

in he_wall_actions.tpl
remplace
{$action_text|nl2br|replace:"[media]":$action_media}
with
{$action_text|nl2br|hashtag|replace:"[media]":$action_media}

ready more reputation please
demo in:
http://coolx.x10.mx/home.php
[Spam Link Removed]
and If like it , please + reputation

#2 DPName

DPName

    Level 1

  • Members
  • Level
  • 10 points
  • 12 posts

Posted 09 October 2013 - 12:57 AM

Ahh, the one spamming links on Yettr. What does this mod do? Provide illustration.

#3 angeldelamuertex

angeldelamuertex

    Level 4

  • Banned
  • Level
  • 69 points
  • 181 posts
    • Gender:Not Telling
    • Software:SE 3.1x

Posted 09 October 2013 - 03:12 AM

hahaha who would do spam?, lol xD, you can create a code like and replace url, this code searches and replaces the text published all mension, hastag, links, is similar to replacing smiles :3

Attached Files

  • Attached File  demo.jpg   13.51KB   27 downloads

[Spam Link Removed]
and If like it , please + reputation

#4 DPName

DPName

    Level 1

  • Members
  • Level
  • 10 points
  • 12 posts

Posted 22 October 2013 - 05:56 PM

There is already functionality built in to do this. You use autosuggest, include it into HE wall or other input, allow Event trigger @ to drop down list, then choose a user. I might do this today, the other suggestions are way to complicated than they need to be.

I often wonder how many people completely forgot about the autosuggest.

#5 angeldelamuertex

angeldelamuertex

    Level 4

  • Banned
  • Level
  • 69 points
  • 181 posts
    • Gender:Not Telling
    • Software:SE 3.1x

Posted 23 October 2013 - 06:23 AM

you use ither script :
http://daniel-zahari...uery-textntags/
, sorry no know finish work :3

Attached Files

  • Attached File  demo.jpg   70.61KB   26 downloads

[Spam Link Removed]
and If like it , please + reputation

#6 billgates786

billgates786

    Level 1

  • Members
  • Level
  • 17 points
  • 17 posts

Posted 13 November 2014 - 11:23 AM

Did someone get this to work?

 

you use ither script :
http://daniel-zahari...uery-textntags/
, sorry no know finish work :3



#7 laticat

laticat

    Level 1

  • Members
  • Level
  • 22 points
  • 24 posts
    • Gender:Not Telling
    • Software:SE 3.1x

Posted 14 November 2014 - 04:24 AM

i am sorry, i am no finish script in old version u.u :/, in new version no is posible add this script u.u






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users


All the resources listed here are just for testing purpose and they shouldn't be used at any commercial environment without a valid license.
Those are for users who wants to try them before buy. Help the developer to build it better by purchasing them from original authors.