Author |
Message |
draxx
Involved


Joined: Nov 19, 2003
Posts: 282
|
Posted:
Sat Mar 14, 2009 2:18 pm |
|
Here when Raven posts a news article and you mouseover his name on the "posted by" link its for the site "ravenphpscripts.com".
When I mouseover my news as the site admin it shows a mailto:emailaddress
I have deleted just about everything I can find in theme.php and it still shows as Posted by Admin with a mailto: link.
Any idea where I can tell it to stop showing the email address? |
|
|
|
 |
Raven
Site Admin/Owner

Joined: Aug 27, 2002
Posts: 17088
|
Posted:
Sat Mar 14, 2009 3:27 pm |
|
Are you using the fisubice theme that ships with RN v2.30.01? That's code I hacked back in 2005  |
|
|
|
 |
draxx

|
Posted:
Sat Mar 14, 2009 3:36 pm |
|
Yep I am using that theme and I tried a few others that also seem to do it.
In the theme I see your comments: You can see where I tried to stick the URL in instead of the modules.php=userinfo stuff
Code:
/************************************************************/
/* Function themearticle() */
/* */
/* This function format the stories on the story page, when */
/* you click on that 'Read More...' link in the home */
/************************************************************/
function themearticle ($aid, $informant, $datetime, $title, $thetext, $topic, $topicname, $topicimage, $topictext, $notes) { //montego - added $notes for RavenNuke
global $admin, $sid, $tipath;
$thetext = '<div>'.$thetext.'</div>';
$posted = _POSTEDON.' '.$datetime.' '._BY.' ';
$posted .= get_author($aid);
if (!empty($notes)) {
$notes = '<br /><b>'._NOTE.'</b> <div>'.$notes.'</div>';
} else {
$notes = '';
}
if ($aid == $informant) {
$content = $thetext.$notes;
} else {
if(!empty($informant)) {
global $admin, $user;
if (is_user($user)||is_admin($admin)) $content = '<a href="givemealink.com"><i>'.$informant.'</i></a> ';
else $content = $informant.' ';//Raven 10/16/2005
} else {
$content = $anonymous.' ';
}
$content .= '<i>'._WRITES.'</i> <div>'.$thetext.'</div>'.$notes;
}
$tmpl_file = 'themes/fisubice/story_page.html';
$thefile = implode('', file($tmpl_file));
$thefile = addslashes($thefile);
// $thefile = '\$r_file="'.$thefile.'";';
$thefile = '$r_file="'."$thefile".'";';
eval($thefile);
print $r_file;
}
|
|
|
|
|
 |
JoAnne
Worker


Joined: Oct 18, 2005
Posts: 127
Location: NYC
|
Posted:
Sat Mar 14, 2009 4:32 pm |
|
draxx wrote: | Here when Raven posts a news article and you mouseover his name on the "posted by" link its for the site "ravenphpscripts.com".
When I mouseover my news as the site admin it shows a mailto:emailaddress
I have deleted just about everything I can find in theme.php and it still shows as Posted by Admin with a mailto: link.
Any idea where I can tell it to stop showing the email address? |
The same thing is occurring on my updated v2.30.01 sites
I didn't realize it until you brought it to my attention  |
|
|
|
 |
j4rdin
Worker


Joined: May 26, 2006
Posts: 153
|
Posted:
Sat Mar 14, 2009 4:45 pm |
|
Raven wrote: | Are you using the fisubice theme that ships with RN v2.30.01? That's code I hacked back in 2005 |
Just found this post. I'm using the RavenIce theme and I've just checked on posts made since my upgrade to RN2.30.01 and before the upgrade.
On the main site in the route directory all is ok, shown the website when mousing over the posted by. But on my subdomain all posts show the mailto: as the previous poster has noticed. Did RavenIce get modified in the same way as Fisubice was?
John |
|
|
|
 |
Raven

|
Posted:
Sat Mar 14, 2009 7:28 pm |
|
We will look into this and post back with our findings. Thanks. |
|
|
|
 |
draxx

|
Posted:
Sat Mar 14, 2009 9:21 pm |
|
Okay if its any help I have searched for "mailto"
I have looked in the news language file
and the news module index.php
and the template language file
and the all the .html parts of the template
oh and the .css file
and the main language file
and I have replaced.. well first I tried just removing them ... all links in theme.php that included or referenced $aid and $informant.
Thats when I popped another grey hair and decided to come here
Thanks Raven! Hope this helps. |
|
|
|
 |
Raven

|
Posted:
Sat Mar 14, 2009 10:18 pm |
|
It al helps - Thanks. We will get to it as soon as we can. |
|
|
|
 |
montego
Site Admin

Joined: Aug 29, 2004
Posts: 9457
Location: Arizona
|
Posted:
Tue Mar 17, 2009 6:55 am |
|
I had even removed the reference to a person's website URL in the news comments recently as it was just an invitation to spam news article comments. Might be another one to check. That code is in modules/News/comments.php |
_________________ Only registered users can see links on this board! Get registered or login!
Only registered users can see links on this board! Get registered or login! |
|
|
 |
draxx

|
Posted:
Wed Mar 18, 2009 10:48 am |
|
modules/news/comments.php - nothing I could see here was doing it.
I really want rid of that email address. I have refrained from posting any news until .... |
|
|
|
 |
Raven

|
Posted:
Wed Mar 18, 2009 11:25 am |
|
Look in mainfile.php for this function
Code:function get_author($aid) {
global $prefix, $db;
static $users;
if (isset($users[$aid]) AND is_array($users[$aid])) {
$row = $users[$aid];
} else {
$sql = 'SELECT url, email FROM '.$prefix.'_authors WHERE aid=\''.$aid.'\'';
$result = $db->sql_query($sql);
$row = $db->sql_fetchrow($result);
$users[$aid] = $row;
}
$aidurl = stripslashes($row['url']);
$aidmail = encode_mail(stripslashes($row['email']));
if (!empty($aidurl) && isset($aidurl) && $aidurl != 'http://') {
$aid = '<a href="'.$aidurl.'">'.$aid.'</a>';
} elseif (!empty($aidmail) && isset($aidmail)) {
$aid = '<a href="mailto:'.$aidmail.'">'.$aid.'</a>';
} else {
$aid = $aid;
}
return $aid;
}
|
|
|
|
|
 |
draxx

|
Posted:
Wed Mar 18, 2009 12:08 pm |
|
Yep thats it. Dident think to look there. Thank you!  |
|
|
|
 |
Raven

|
Posted:
Wed Mar 18, 2009 2:45 pm |
|
|
|
 |
JoAnne

|
Posted:
Wed Mar 18, 2009 4:39 pm |
|
Raven wrote: | |
Do we remove that code or just comment it out?
Thanks
JoAnne |
|
|
|
 |
draxx

|
Posted:
Wed Mar 18, 2009 4:50 pm |
|
Find the red line:
$aidurl = stripslashes($row['url']);
$aidmail = encode_mail(stripslashes($row['email']));
if (!empty($aidurl) && isset($aidurl) && $aidurl != 'http://') {
$aid = '<a href="'.$aidurl.'">'.$aid.'</a>';
} elseif (!empty($aidmail) && isset($aidmail)) {
$aid = '<a href="mailto:'.$aidmail.'">'.$aid.'</a>';
} else {
$aid = $aid;
}
return $aid;
}
Change that line to this
Code:
$aid = '<a href="index.html">'.$aid.'</a>';
|
and the link over the name will refer them to the homepage ... kinda like what raven does... but I'm sure you could alter some more code and have it refer to the admins profile or whoever. |
|
|
|
 |
JoAnne

|
Posted:
Wed Mar 18, 2009 5:40 pm |
|
draxx wrote: |
and the link over the name will refer them to the homepage ... kinda like what raven does... but I'm sure you could alter some more code and have it refer to the admins profile or whoever. |
Homepage is so much better than email!
Thank you so much Raven and draxx!
JoAnne |
|
|
|
 |
j4rdin

|
Posted:
Thu Mar 19, 2009 11:11 am |
|
Raven wrote: | Look in mainfile.php for this function |
Thanks Raven, so much easier than messing around with the themes.
John  |
|
|
|
 |
Susann
Moderator

Joined: Dec 19, 2004
Posts: 3191
Location: Germany:Moderator German NukeSentinel Support
|
Posted:
Mon Sep 14, 2009 8:41 am |
|
Just added:
$aid = '<a href="/">'.$aid.'</a>';
Maybe this should be a sticky.  |
|
|
|
 |
|