71
karuna
Re: Is there an image resizer hack for Newbb?
  • 2004/4/30 2:55

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


a hack from http://www.bbchen.org

let the images auto fit the table in newbb.

(1). add this function in /include/xoops.js

CODE
//Hack Begin==Add image-autoresizing feature===//
function CaricaFoto(img){
foto1= new Image();
foto1.src=(img);
Controlla(img);
}
function Controlla(img){
if((foto1.width!=0)&&(foto1.height!=0)){
viewFoto(img);
}else{
funzione="Controlla('\"+img+\"')";
intervallo=setTimeout(funzione,20);
}
}
function viewFoto(img){
largh=foto1.width;
altez=foto1.height;
stringa="width="+largh+",height="+altez;
finestra=window.open('','',stringa);
finestra.document.write ("");
finestra.document.write ("");
finestra.document.close();
return false;
}
//Hack End/*/




(2).in /class/module.textsanitizer.php

##find:

CODE
$replacements[] = '';
$replacements[] = '';
$replacements[] = '\\4';
$replacements[] = '\\3';


##replace it with:

CODE

$replacements[] = "点击查看大图screen.width-540)this.width=screen.width-500\" />
";
$replacements[] = "点击查看大图screen.width-540)this.width=540\" />
";
$replacements[] = '\\4';
$replacements[] = '\\3';



##find :

CODE
$patterns[] = "/java script:/si";
$replacements[] = "java script:";



##move it behand :

CODE

function &xoopsCodeDecode(&$text, $allowimage = 1)
{
$patterns = array();
$replacements = array();


##finish



72
karuna
Re: continuous blank will be ignored in the newbb??
  • 2004/4/28 3:50

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


i mean

OOO




OOO

should look like this

OOO
       
O
    
O
    
O
       
O
OOO




73
karuna
Re: Google Indexing
  • 2004/4/28 3:38

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29





74
karuna
Re: Displaying the "Titles" of News at hompage
  • 2004/4/27 16:57

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29





75
karuna
Re: A new autologin hack for 2.0.6
  • 2004/4/27 16:17

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


hmm
i upload these files downloaded from your site.

But it seems that it does not work. and the login form in my site has been integrated to the theme, so maybe is the problem of the theme.



76
karuna
Re: Delete user's messages
  • 2004/4/27 15:51

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


Use phpmyadmin



77
karuna
Re: A new autologin hack for 2.0.6
  • 2004/4/27 11:11

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


i'd like have a try



78
karuna
Re: How to show the pm icon besides the reply icon as well?
  • 2004/4/26 17:28

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


and at first i tired assign a smarty variable like this

if (is_object($xoopsUser)) {
$xoopsTpl->assign('user_pmlink', "\"".sprintf(_SENDPMTO,$topic_post[poster_uname])."\"");
} else {
$xoopsTpl->assign('user_pmlink', '');
}

but failed
Maybe after change $topic_post[poster_uid] to $eachposter->getVar('uid') and change $topic_post[poster_uname] to $eachposter->getVar('uname') as Predator has posted the code will work~~ just guess



79
karuna
Re: How to show the pm icon besides the reply icon as well?
  • 2004/4/26 17:04

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


thanks for your's quick response

JackJ's code works well

Added it to the template file newbb_thread.html

after
<{if $viewer_is_admin == true}>


and

<{elseif $xoops_isuser == true && $xoops_userid == $topic_post.poster_uid}>

and

<{elseif $viewer_can_post == true}>


Thanks again~~



80
karuna
How to show the pm icon besides the reply icon as well?
  • 2004/4/26 16:25

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


I think now it's a bit difficult for a newbie to XOOPS to find the pm icon~~

is the any way to show the pm icon besides the reply icon as well?




TopTop
« 1 ... 5 6 7 (8) 9 10 11 ... 16 »



Login

Who's Online

187 user(s) are online (128 user(s) are browsing Support Forums)


Members: 0


Guests: 187


more...

Donat-O-Meter

Stats
Goal: AU$15.00
Due Date: Jul 31
Gross Amount: AU$0.00
Net Balance: AU$0.00
Left to go: AU$15.00
Make donations with PayPal!

Latest GitHub Commits