Raised This Month: $ Target: $400
 0% 

Again input line too long error


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
bibu
Veteran Member
Join Date: Sep 2010
Old 07-22-2011 , 01:12   Again input line too long error
Reply With Quote #1

What's wrong here, I've tried to split the lines like it has been said in several topics, but it didn't help:

PHP Code:
        const SIZE 2048
        
new msg[SIZE+1], len
        
        len 
formatex(msg[len], SIZE 1"<html>\
        <body bgcolor=^"
#2b2b2b^">\
        
<p style=^"text-align: center;^">\
        <
span style=^"color: #3399ff; \
        font-family: 'trebuchet ms', geneva;^"
>\
        <
strong>\<img src=^"http://mynet.net/cs.png^" \
        
alt="" width=^"403^" height=^"51^" />\
        <
h1>%s</h1><table border=^"1^" \
        
style=^"font-family: 'trebuchet ms'; font-size: 10px;^">\
        <
tr><td><b>Rank</b></td><td><b>Name</b></td>\
        <
td><b>Total Score</b>\
        </
td><td>\
        <
b>Zombies Killed</b>\
        </
td>\
        <
td>\
        <
b>\
        
Nemesis's Killed</b>\
        </td><td><b>Survivor: Zombies Killed</b>\
        </td><td><b>Knife: Zombies Killed</b>\
        </td><td><b>Human'
s Infected</b></td><td>\
        <
b>NemesisHuman's Killed</b>\
        </td><td><b>Survivor'
s Killed</b>\
        </
td><td><b>Human's Killed</b></td></tr>", szTitle) 
__________________
Selling tons of my own private works.
Accepting paid work for clans and communities.
Don't hesitate to contact me.
bibu is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 07-22-2011 , 02:11   Re: Again input line too long error
Reply With Quote #2

format sections at a time.
__________________
fysiks is offline
bibu
Veteran Member
Join Date: Sep 2010
Old 07-22-2011 , 06:50   Re: Again input line too long error
Reply With Quote #3

How?
__________________
Selling tons of my own private works.
Accepting paid work for clans and communities.
Don't hesitate to contact me.
bibu is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 07-22-2011 , 09:12   Re: Again input line too long error
Reply With Quote #4

Quote:
Originally Posted by bibu View Post
How?
Multiple format statements containing pieces of it.
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
Hunter-Digital
Veteran Member
Join Date: Aug 2006
Location: In the Game [ro]
Old 07-22-2011 , 11:08   Re: Again input line too long error
Reply With Quote #5

Just to be sure you're not gonna use format() with back copy, I'll show you the method:

Code:
new msg[2048]
new len = 0

len += formatex(msg[len], charsmax(msg) - len, "<html>")
len += formatex(msg[len], charsmax(msg) - len, "<head></head>")
len += formatex(msg[len], charsmax(msg) - len, "<body>%s</body>", "wtf")
len += formatex(msg[len], charsmax(msg) - len, "</html>")
Still, I think add() could work instead of formatex() aswell... but I never used it =)
__________________
Hunter-Digital is offline
bibu
Veteran Member
Join Date: Sep 2010
Old 07-22-2011 , 12:28   Re: Again input line too long error
Reply With Quote #6

Quote:
Error: Expected token: ",", but found "-string-" on third line.
Has it todo with the html code?

PHP Code:
        len += formatex(msg[len], charsmax(msg) - len"<html><body bgcolor=^"#2b2b2b^"><p style=^"text-align: center;^">")
        
len += formatex(msg[len], charsmax(msg) - len"<span style=^"color#3399ff; font-family: 'trebuchet ms', geneva;^"><strong>")
        
len += formatex(msg[len], charsmax(msg) - len"<img src=^"http://mynet.net/cs.png^" alt="" width=^"403^" height=^"51^" />")
        
len += formatex(msg[len], charsmax(msg) - len"<h1>%s</h1><table border=^"1^"style=^"font-family'trebuchet ms'font-size10px;^">"szTitle)
        
len += formatex(msg[len], charsmax(msg) - len"<tr><td><b>Rank</b></td><td>")
        
len += formatex(msg[len], charsmax(msg) - len"<b>Name</b></td>    <td><b>Total Score</b></td>")
        
len += formatex(msg[len], charsmax(msg) - len"<td><b>Zombies Killed</b></td><td><b>Nemesis's Killed</b></td>")
        
len += formatex(msg[len], charsmax(msg) - len"<td><b>Survivor: Zombies Killed</b></td><td><b>Knife: Zombies Killed</b></td>")
        
len += formatex(msg[len], charsmax(msg) - len"<td><b>Human's Infected</b></td><td><b>Nemesis: Human's Killed</b></td>")
        
len += formatex(msg[len], charsmax(msg) - len"<td><b>Survivor's Killed</b></td>")
        
len += formatex(msg[len], charsmax(msg) - len"<td><b>Human's Killed</b></td></tr>"
__________________
Selling tons of my own private works.
Accepting paid work for clans and communities.
Don't hesitate to contact me.
bibu is offline
Emp`
AMX Mod X Plugin Approver
Join Date: Aug 2005
Location: Decapod 10
Old 07-22-2011 , 13:25   Re: Again input line too long error
Reply With Quote #7

Quote:
Originally Posted by bibu View Post
PHP Code:
alt="" 
Emp` is offline
Send a message via AIM to Emp` Send a message via MSN to Emp` Send a message via Yahoo to Emp` Send a message via Skype™ to Emp`
bibu
Veteran Member
Join Date: Sep 2010
Old 07-22-2011 , 13:30   Re: Again input line too long error
Reply With Quote #8

After those fixes, the plugin has now an infinite loop for the compilation. It doesn't finish at all.
__________________
Selling tons of my own private works.
Accepting paid work for clans and communities.
Don't hesitate to contact me.
bibu is offline
SnoW
Veteran Member
Join Date: Oct 2008
Location: Finland WisdomNuggets: 8
Old 07-22-2011 , 13:55   Re: Again input line too long error
Reply With Quote #9

Quote:
Originally Posted by bibu View Post
After those fixes, the plugin has now an infinite loop for the compilation. It doesn't finish at all.
Now that there is not even an error it is really easy for us to tell what is wrong without you showing the source code.
SnoW is offline
Send a message via MSN to SnoW
bibu
Veteran Member
Join Date: Sep 2010
Old 07-22-2011 , 14:48   Re: Again input line too long error
Reply With Quote #10

How I said, it happend after I edited to the one from post 6.
__________________
Selling tons of my own private works.
Accepting paid work for clans and communities.
Don't hesitate to contact me.
bibu is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:00.


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