PHP Web Host - Quality Web Hosting For All PHP Applications Just Great Software
  Login or Register
 • Home • Downloads • Your Account • Forums • 

View next topic
View previous topic


Google
 
Web RavenPHPScripts (This Site)
Post new topic   Reply to topic
Author Message
Donovan
Client


Joined: Oct 07, 2003
Posts: 675
Location: Ohio

PostPosted: Mon Mar 31, 2008 9:17 am Reply with quote Back to top

Anybody have any experience with modules made for Dragonfly? Anybody ever "port" a Dragonfly module over to PHPNuke?
View user's profile Send private message Visit poster's website ICQ Number
Donovan
Client


Joined: Oct 07, 2003
Posts: 675
Location: Ohio

PostPosted: Mon Mar 31, 2008 10:45 am Reply with quote Back to top

Could I add this to include/functions.php and save myself the headache of trying to change this everywhere in the Dragonfly module.

Reason being the way Dragonfly handles linking:

Code:
Nuke: echo "<a href=\"index.php\">Return</a> to the main page.<br>";
Dragonfly:  echo "<a href=\"" . getlink() . \">Return</a> to the main page.<br>";

Nuke: echo "<a href=\"admin.php\">Return</a> to the admin section.<br />";
Dragonfly:  echo "<a href=\"" . adminlink() . \">Return</a> to the admin section.<br />";

Nuke: echo "<a href=\"modules.php?name=Your_Account&op=userinfo\">Your Account</a><br />";
Dragonfly:  echo "<a href=\"".getlink("Your_Account&amp;op=userinfo)."\">Your Account</a><br />";


Here is the function from the Dragonfly CMS


Code:
function getlink($url='', $UseLEO=true, $full=false)
{
   global $module_name, $mainindex, $MAIN_CFG, $BASEHREF;
   if (empty($url) || $url[0] == '&') $url = $module_name.$url;
   if ($MAIN_CFG['global']['GoogleTap'] && $UseLEO) {
      $url = ereg_replace('&amp;', '/', $url);
      $url = ereg_replace('&', '/', $url);
      $url = str_replace('?', '/', $url);
      if (ereg('/file=', $url)) {
         $url = ereg_replace('/file=', '/', $url);
      }
      if (ereg('#', $url)) {
         $url = ereg_replace('#', '.html#', $url);
      } else $url .= '.html';
   } else {
      $url = "$mainindex?name=".$url;
   }
   if ($full) $url = $BASEHREF.$url;
   return $url;
}
function adminlink($url='', $full=false)
{
   global $adminindex, $op, $module_name, $MAIN_CFG;
   if (empty($op) && !empty($module_name)) $op = $module_name;
   if (empty($url)) { $url = $op; }
   if ($url[0] == '&') { $url = "$adminindex?op=$op".$url; }
   else { $url = "$adminindex?op=".$url; }
   if ($full) $url = 'http://'.$MAIN_CFG['server']['domain'].$MAIN_CFG['server']['path'].$url;
   return $url;
}
View user's profile Send private message Visit poster's website ICQ Number
Donovan
Client


Joined: Oct 07, 2003
Posts: 675
Location: Ohio

PostPosted: Mon Mar 31, 2008 5:40 pm Reply with quote Back to top

So an example of the code I would change is:

Code:
echo '
      <div align="right">[
        <a href="'.getlink('&event='.$edata['event'].'&screen=0').'">'._MRC_TABLES.'</a> |
        <a href="'.getlink('&event='.$edata['event'].'&screen=1').'">'._MRC_FIXTURES.'</a> |
        <a href="'.getlink('&event='.$edata['event'].'&screen=2').'">'._MRC_CALENDAR.'</a> |


Would much rather just add the function modified for Nuke. Anybody have any input on changing these functions to work with Nuke?
View user's profile Send private message Visit poster's website ICQ Number
gregexp
The Mouse Is Extension Of Arm


Joined: Feb 21, 2006
Posts: 1465
Location: In front of a screen....HELP! lol

PostPosted: Mon Mar 31, 2008 9:21 pm Reply with quote Back to top

I would change only the function, as the output should be the same.

The only thing you should have to do, is recode the way it defines certain variables within it, and how it outputs them.

It wouldnt be too hard, I cant think of each one of the variables off hand, but it should be fairly simple to determine what should go where.
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number
montego
Site Admin


Joined: Aug 29, 2004
Posts: 7236
Location: Arizona

PostPosted: Thu Apr 03, 2008 5:38 am Reply with quote Back to top

Donovan, I see no reason why not to change those too functions. You can strip out all the "GoogleTap" stuff as RavenNuke already has ShortLinks or you can install ShortLinks and just use that instead (as it will work for all the other true nuke modules).
View user's profile Send private message Visit poster's website
Display posts from previous:       
Post new topic   Reply to topic

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Forums ©
 

All logos and trademarks in this site are property of their respective owner.
The comments are property of their posters, all the rest © 2002-2008 by Raven
Proud to be listed at Lobo Links Web Directory

You can syndicate our news using the file xml

CSE HTML Validator Helped Clean up This Page! [Valid RSS] valid RSS 2.0 Valid robots.txt Stop Spam Harvesters, Join Project Honey Pot

Website engines core code is © copyright by PHP-Nuke but has been heavily patched and modified by myself and others.
PHP-Nuke is a free software released under the GNU/GPL.


:: fisubice phpbb2 style by Daz :: PHP-Nuke theme by www.nukemods.com ::

:: fisubice Theme Recoded To 100% W3C CSS & HTML 4.01 Transitional Compliance by Raven and 64bitguy ::

:: W3C CSS Compliance Validation :: W3C HTML 4.01 Transitional Compliance Validation ::

zerosum