1
Korfmann
Re: iStats without Javascript?
  • 2005/3/11 21:18

  • Korfmann

  • Just popping in

  • Posts: 7

  • Since: 2005/2/1 2


Hm, that`s bad. Is there a ready solution for that? I think that other counters include a 1px transparent gif for "non-javascript-counting". maybe this is a possibility?



2
Korfmann
iStats without Javascript?
  • 2005/3/11 20:00

  • Korfmann

  • Just popping in

  • Posts: 7

  • Since: 2005/2/1 2


I tried iStats and find it very useful. But what is when some users have deactivated javascript? are they not counted by iStats?



3
Korfmann
WordBook Autolink
  • 2005/3/9 20:04

  • Korfmann

  • Just popping in

  • Posts: 7

  • Since: 2005/2/1 2


Hello,

this ist my first "quick & dirty" hack. The idea was, to autolink Glossary terms system wide. I don´t know, if anyone cares about or solved this problem otherwise. i find it very useful. This Hack based on XOOPS 2.0.9.2 Stable and WordBook 1.12.

All Changes were made in this file: "/class/module.textsanitizer.php"

Add this Array at the top of the class:
var $glossary = array();


Add this function (based on smiley function) and replace [YOUR_URL] with your base URL:

function &glossar($message)
        {
        
$db =& Database::getInstance();
        if (
count($this->glossary == 0)) {
            if (
$getglossar $db->query("SELECT term,entryID FROM "$db->prefix("wbentries"))){
                while (
$glossar $db->fetchArray($getglossar)){
                    
$id $glossar['entryID'];
                    
$term $glossar['term'];
                    
$termlink '<a href="[YOUR_URL]/modules/wordbook/entry.php?entryID='$id '" target="_blank">' $term '?</a>';
                    
$message =& preg_replace("/((<[^>]*)|$term)/ie"'"2"=="1"? "1":"$termlink"'$message,1);
                    
array_push($this->glossary$glossar);
                    
                }
            }
        }
        elseif (
is_array($this->glossary)){
            foreach(
$this->glossary as $glossar) {
                
$id $glossar['entryID'];
                    
$term $glossar['term'];
                    
$termlink '<a href="[YOUR_URL]/modules/wordbook/entry.php?entryID='$id '" target="_blank">' $term '?</a>';
                    
$message =& preg_replace("/((<[^>]*)|$term)/ie"'"2"=="1"? "1":"$termlink"'$message,1);
            }
        }
        return 
$message;
    }


Find this: "function &displayTarea"
and add the following line before return:
$text =& $this->glossar($text);


Do the same with the function "function &previewTarea".

Ok, thats it. It´s not perfect, but it works for me. Suggestions are very welcome



4
Korfmann
Main- and Subpages in one Database?
  • 2005/2/1 23:05

  • Korfmann

  • Just popping in

  • Posts: 7

  • Since: 2005/2/1 2


i want to set up one mainpage with many subpages (ca. 200 - 300). the subpages should be appear as independent website and should be custumizeable with the global templates.

there will be some "global content" like forum, news etc and some "local content" on the sub-pages like photos, service descriptions. at last there will be some "mixed content". this will be entered from the local partners for their sub-homepages and should be avaible for the global site.

my idea is to add some fields like "subPage-Id" to seperate the contents. for this are some deeper changes in the system necessary. so maybe you could give me some tipps or somebody has better ideas?




TopTop



Login

Who's Online

217 user(s) are online (149 user(s) are browsing Support Forums)


Members: 0


Guests: 217


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits