Portal    Foro    Buscar    FAQ    Registrarse    Conectarse


JanuWeb.Com  Informa

JanuWeb es una Comunidad abierta a todos los internautas.
Pero algunos de sus contenidos (Adjuntos, Descargas, Grupos...) sólo son accesibles a usuarios registrados.

Regístrate y disfruta al completo de la web.



Publicar Nuevo Tema  Responder al Tema Página 1 de 1
 
Soporte Php
Autor Mensaje
Responder Citando  
Mensaje Soporte Php 
 
pues no se donde preguntar esto, asi que pregunto aqui que hay algun informatico.
No es soporte para el icy, asi que al final dejo otros datos de soporte.

quiero hacer q el cookbook/autolink.php redireccione a Vocabulario.Nombre, en vez de a GrupoActual.Nombre.
me explico:
esa extension sirve para palabras comunmente utilizadas, las detecta como neccesarias para añadir al wiki y las marca como link a Nombredelgrupoactual.Termino. Si existen las linka, Si no, las linka en rojo para q la edites tu.... pero como la mayoria de palabras aparecen en manuales.. es obvio q en Manuales.PalabraDeVocabulario no va existir... por eso quiero q no detecte la pagina actual.. q siempre linke a Vocabulario.Termino

Código: [Descargar] [Ocultar]
  1. #set predefined values  
  2. $AutoLinkList = array();  
  3. $AutoLinkTime = 0;  
  4. SDV($AutoLinkMinSize,2);  
  5.  
  6. # read the comparison table from a file and place it in an array  
  7. function AutoLinkListRead($group) {  
  8.    global $AutoLinkList, $AutoLinkTime,$WorkDir,$AutoLinkMinSize;  
  9.    # read information from file and fill array  
  10.    $filename =  "$WorkDir/.autolink-$group";  
  11.    if (file_exists($filename)) {  
  12.        $AutoLinkTime = filemtime($filename);  
  13.    }  
  14.    if  ($fp=@gzopen($filename, "r")) {  
  15.        while (!gzeof($fp)) {  
  16.            $line = rtrim(gzgets($fp, 4096));  
  17.            $part = explode ("%0a", $line); # delimiter between data is string "%0a"  
  18.            if (strlen($part[1])>=$AutoLinkMinSize) {  
  19.                $AutoLinkList[$part[0]] = $part[1]; # add entry to array  
  20.            }  
  21.        }  
  22.        gzclose ($fp);  
  23.    }  
  24. }  
  25.  
  26. # sorting helper function to sort regarding textsize in mind, from longest to smallest  
  27. function sizersort($a,$b) {  
  28.    if (strlen($a)==strlen($b)) {  
  29.        return 0;  
  30.    }  
  31.    return (strlen($a) > strlen($b)) ? -1 : 1;  
  32. }  
  33.  
  34. # check whether some files have been added/removed  
  35. function AutoLinkListUpdate($group) {  
  36.    global $AutoLinkTime,$AutoLinkList,$WorkDir,$SearchPatterns,$AutoLinkMinSize;  
  37.    $modified = false;  
  38.    $filename =  "$WorkDir/.autolink-$group";  
  39.    if ($handle = opendir($WorkDir)) { # get filenames that are matching  
  40.        while (false !== ($file = readdir($handle))) {  
  41.            if ($file != "." && $file!= ".." && substr($file,0,strlen($group)+1) == "$group.") {  
  42.                $count=0;  
  43.                if (isset($SearchPatterns['default'])) {  
  44.                    foreach($SearchPatterns['default'] as $v) { #check for in search excluded files  
  45.                        $count += preg_match($v,$file);  
  46.                    }  
  47.                }  
  48.                if ($count==0) { #save only not excluded files  
  49.                    $matches[]=$file;  
  50.                }  
  51.            }  
  52.        }  
  53.        closedir($handle);  
  54.    }  
  55.    # check if the filename/title combination is already included, if not, add it, check also for changes  
  56.    foreach($matches as $v){  
  57.        if (file_exists($v) && filemtime($v) >= $AutoLinkTime){  
  58.            unset($AutoLinkList[$v]);  
  59.        }  
  60.        if (empty($AutoLinkList[$v])) { # add only missing entries  
  61.            $modified = true;  
  62.            $page = ReadPage($v, READPAGE_CURRENT);  
  63.            if (empty($page['title'])){  
  64.                $AutoLinkList[$v] = substr(strstr($v,"."),1);  
  65.            }  
  66.            else {  
  67.                $AutoLinkList[$v] = trim($page['title']);  
  68.            }  
  69.            if (strlen($AutoLinkList[$v])<$AutoLinkMinSize) {  
  70.                unset($AutoLinkList[$v]);  
  71.            }  
  72.        }  
  73.    }  
  74.    # save filename/title combinations  
  75.    if ($modified) {  
  76.        if  ($fp=@gzopen($filename, "w")) {  
  77.            foreach($AutoLinkList as $k => $v) {  
  78.                if (substr($k,0,strpos($k,".")) == $group) {  
  79.                    gzwrite($fp, "$k%0a$v\n");  
  80.                }  
  81.            }  
  82.            gzclose ($fp);  
  83.        }  
  84.    }  
  85. }  
  86.  
  87. #replace with pagenames  
  88. function AutoLinkSet($pattern) {  
  89.    global $AutoLinkList,$pagename;  
  90.    # convert Pattern to Link, ignore selflinks  
  91.    foreach ($AutoLinkList as $k => $v) {  
  92.        if ($v==$pattern ) {  
  93.            return ($k!=$pagename) ? MakeLink($pagename,$k,$v) : $pattern;  
  94.        }  
  95.    }  
  96. }  
  97.  
  98. # activate automatic link creation  
  99. function AutoLinkActivate($groups) {  
  100.    global $AutoLinkList,$WorkDir;  
  101.    $group = explode (" ",$groups);  
  102.    foreach ($group as $v) {  
  103.        AutoLinkListRead($v);  
  104.        AutoLinkListUpdate($v);  
  105.    }  
  106.    unset($AutoLinkList[""]); # remove empty entry  
  107.    # check whether files do exist, if not remove from filename/title list  
  108.    foreach($AutoLinkList as $k => $v) { #0,1 sec  
  109.        if (!file_exists("$WorkDir/$k")) {  
  110.            unset($AutoLinkList[$k]);  
  111.        }  
  112.    }  
  113.    uasort($AutoLinkList,"sizersort"); # sort array on size, largest entries first  
  114.    $AutoLinkPattern = implode("|",array_unique($AutoLinkList));  
  115.    $searcharray = array("\\", "^", "$", ".", "[" , "]", "(", ")", "?", "*", "+", "{", "}", "/" );  
  116.    $replacearray = array("\\\\", "\^", "\\$", "\.", "\[", "\]", "\(", "\)", "\?", "\*", "\+", "\{", "\}", "\/");  
  117.    $AutoLinkPattern = str_replace($searcharray,$replacearray,$AutoLinkPattern);  
  118.    Markup('autolinklinks', '>wikilink' ,"/($AutoLinkPattern)/e","Keep(AutoLinkSet('$0'),'L')");  
  119. }  
  120.  


Espero que se me haya entendido porque no estoy muy ducho en php.
www.wikimoto.es
en un pmwiki





_________________________________
WebMaster:: EliteMoviles
phpbb 3.0.3
Server:: Sotem
Plantilla basada en subsilver2

WebMaster:: ClubiFone
phpbb 3.0.3
Server:: VPS de pago zipservers
Plantilla basada en subsilver2
Desconectado Ver perfil del usuario Enviar Mensaje Privado Visitar sitio Web del Usuario
Descargar Mensaje Volver arriba Página Inferior
Responder Citando  
Mensaje Re: Soporte Php 
 
Uffff.
Me voy a marcar éste tema y miraré de entender el código.
No prometo resultados... xD





_________________________________
Image
Desconectado MSN Messenger Skype Yahoo Messenger Ver perfil del usuario Enviar Mensaje Privado Visitar sitio Web del Usuario Ver la Galería Personal del usuario
Descargar Mensaje Volver arriba Página Inferior
Responder Citando  
Mensaje Re: Soporte Php 
 
gracias, Janu, siempre puedo contar contigo  
pero no hagas nada todavia. Estamos mirando a ver si cambiamos el pmwiki por el mediawiki que esta mas completo y no tiene fallitos que son pocos, pero molestos.

Si no cambiamos y lo necesito, te aviso.





_________________________________
WebMaster:: EliteMoviles
phpbb 3.0.3
Server:: Sotem
Plantilla basada en subsilver2

WebMaster:: ClubiFone
phpbb 3.0.3
Server:: VPS de pago zipservers
Plantilla basada en subsilver2
Desconectado Ver perfil del usuario Enviar Mensaje Privado Visitar sitio Web del Usuario
Descargar Mensaje Volver arriba Página Inferior
Responder Citando  
Mensaje Re: Soporte Php 
 
Ok, no hago nada.
Ya avisarás.





_________________________________
Image
Desconectado MSN Messenger Skype Yahoo Messenger Ver perfil del usuario Enviar Mensaje Privado Visitar sitio Web del Usuario Ver la Galería Personal del usuario
Descargar Mensaje Volver arriba Página Inferior
Mostrar mensajes anteriores:   
Ocultar¿Este tema fue útil?
Compartir este tema
blinkslist.com blogmarks.net co.mments.com del.icio.us digg.com newsvine.com facebook.com fark.com feedmelinks.com furl.net google.com linkagogo.com ma.gnolia.com meneame.net netscape.com reddit.com shadows.com simpy.com slashdot.org smarking.com spurl.net stumbleupon.com technorati.com favorites.live.com yahoo.com DIGG ITA Fai Informazione KiPapa Ok Notizie Segnalo
OcultarTemas Parecidos
Tema Autor Foro Respuestas Último Mensaje
El tema está bloqueado: no pueden editarse ni agregar mensajes. Nota: Soporte para phpBB JANU1535 Soporte phpBB 2 0 06 Sep 2006 00:15 Ver último mensaje
JANU1535
El tema está bloqueado: no pueden editarse ni agregar mensajes. Nota: Soporte para phpBB XS JANU1535 Soporte phpBB XS 2 0 05 Sep 2006 19:03 Ver último mensaje
JANU1535
El tema está bloqueado: no pueden editarse ni agregar mensajes. Nota: Soporte Para PhpBB 3 JANU1535 Soporte phpBB 3 Olympus 0 11 Nov 2007 22:54 Ver último mensaje
JANU1535
El tema está bloqueado: no pueden editarse ni agregar mensajes. Nota: Soporte para phpBB Plus JANU1535 Soporte phpBB Plus 0 06 Sep 2006 00:13 Ver último mensaje
JANU1535

Publicar Nuevo Tema  Responder al Tema  Página 1 de 1
 

Usuarios navegando en este Tema: 0 Registrados, 0 Ocultos y 0 Invitados
Usuarios Registrados conectados: Ninguno


 
Lista de Permisos
No puede crear mensajes
No puede responder temas
No puede editar sus mensajes
No puede borrar sus mensajes
No puede votar en encuestas
No puede adjuntar archivos
No Puede descargar archivos
Puede enviar eventos al Calendario



  



 

JanuWeb.Com  Destaca


JanuWeb.ComJanuWeb.OrgJanuBlog.Com están alojadas en Sotem.es • © 2006, 2008

MuchoGrafico - Paz y Justicia - phpBB-Es - Icy Phoenix España - Ciber Morph - Lphant - EDDB - CoMuNiDaD ThE KuKa
RYLNet - phpBBMODs.Es - ZonaManolo - Directorio phpBB-Es - ModMovil - AyudaPC - Mas Pi - Madelman