AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   img in motd (https://forums.alliedmods.net/showthread.php?t=144202)

Debesėlis 11-30-2010 09:45

img in motd
 
Why doesn`t show img?

PHP Code:

new g_WebSite;

public 
plugin_init ( ) {
    
g_WebSite register_cvar"amx_website""www.--.com" );
}
    
// get your pcvar value as a string
    
new szURL[33];
    
get_pcvar_string(g_WebSiteszURL32);
    
iLen += formatexsBufferiLen ], CharsMaxsBuffer ) - iLen,  "<center><img  src='http://%s/images/image_01.jpg'></img></center><br>"szURL); 


Exolent[jNr] 11-30-2010 13:06

Re: img in motd
 
You have an unnecessary space in the img tag and also img has no closing tag.

PHP Code:

    iLen += formatexsBufferiLen ], CharsMaxsBuffer ) - iLen,  "<center><img src='http://%s/images/image_01.jpg'></center><br>"szURL); 

Try printing the variable to make sure the website is right.

PHP Code:

    log_amx"website: %s"sBuffer ); 


Debesėlis 11-30-2010 13:21

Re: img in motd
 
good thank you.

fysiks 11-30-2010 18:22

Re: img in motd
 
I didn't think single quotes worked in HTML for parameters.


All times are GMT -4. The time now is 11:20.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.