rejetto forum
May 22, 2012, 04:51:19 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: This forum is free, you do NOT need to register to post. But you may.
PROBLEMS? QUESTIONS? CLICK HERE!
Fill the survey!
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: "up" button is bug  (Read 3263 times)
0 Members and 1 Guest are viewing this topic.
catgirl
Regular poster
**
Offline Offline

Posts: 17



View Profile
« on: April 16, 2004, 12:34:52 AM »

"up" button is bug.
no support chinese encode.(Only "UP"button)

Logged
catgirl
Regular poster
**
Offline Offline

Posts: 17



View Profile
« Reply #1 on: April 16, 2004, 12:49:58 AM »

press "up" contain chinese character.
404 file not find
Logged
Pavel Rus
Occasional poster
*
Offline Offline

Posts: 7

331025557
View Profile WWW
« Reply #2 on: April 16, 2004, 01:01:42 AM »

This bug complete fix, if rejetto add in you sources code
this string:
// build up base table
table:=NIL;
addArray(table, [
  '%timestamp%', DateTimeToStr(now()),
  '%version%', VERSION,
  '%uptime%', uptimestr(),
  '%folder%', includeTrailingChar('/', decodeURL(folder.url())),
//************** My modification ********************************
{correct russian or other chars in url in header "Up"  \\hslib.encodeURL\\}
  '%parent-folder%', hslib.encodeURL(includeTrailingChar('/', decodeURL(folder.parenturl())),True,True,False)
//************** End My modification ********************************
]);
Logged
catgirl
Regular poster
**
Offline Offline

Posts: 17



View Profile
« Reply #3 on: April 16, 2004, 01:21:18 AM »

Not compile Sad

 Sad  :cry:
Logged
Pavel Rus
Occasional poster
*
Offline Offline

Posts: 7

331025557
View Profile WWW
« Reply #4 on: April 16, 2004, 02:49:31 AM »

what is not compile?
I can help you.
I fix bugs in sources code.
If you have any questions please go to my icq 331025557
or my mail skeeper@nm.ru
Logged
rejetto
Administrator
Insane programmer
*
Offline Offline

Italy Italy

Posts: 11824


View Profile
« Reply #5 on: April 16, 2004, 05:41:28 AM »

Quote from: "Pavel Rus"
'%parent-folder%', hslib.encodeURL(includeTrailingChar('/', decodeURL(folder.parenturl())),True,True,False)

yes, i get the idea.

it is more desirable to not call the hslib.encodeURL(), but use the hiding function present in main module ... when possible.

i moved fullEncode:=TRUE; before the // build up base table
and inserted a call to encodeURL().
i hope this will work.
Logged
rejetto forum
« Reply #5 on: April 16, 2004, 05:41:28 AM »

Do you like this software? Consider even $2
 Logged
Pavel Rus
Occasional poster
*
Offline Offline

Posts: 7

331025557
View Profile WWW
« Reply #6 on: April 16, 2004, 07:39:50 AM »

For comlete this problem i add code
i add new key word %efolder%
in template it is
-------------------------------------------------------------------------------
[files]
<div class=label>%number-folders% folders,  %number-files% files - Total: %total-size%</div>
<table cellpadding=5>
<th><a href="%efolder%?sort=n"><span class=column>Filename</span></a>
<th><a href="%efolder%?sort=s"><span class=column>Filesize</span></a>
<th><a href="%efolder%?sort=t"><span class=column>Filetime</span></a>
<th class=column>Hits
%list%
</table>
-------------------------------------------------------------------------------
in programm

// build final page
if list='' then list:=tpl['nofiles']
else
  begin
  table2:=table;
//************** My modification ********************************
  {correct russian chars in url in header "File , Size, Date Time"}
  i:=0;
  while i < length(table2) do
  begin
    if table2='%folder%' then
    begin
      temp:=hslib.encodeURL(table2[i+1],True,True,False);
      addArray(table2, ['%efolder%',temp]);
      break;
    end;
    inc(i,2);
  end;
//************** End My modification *********************
  addArray(table2, ['%list%',list]);
  list:=x_template(tpl['files'], table2);
  end;
Logged
rejetto
Administrator
Insane programmer
*
Offline Offline

Italy Italy

Posts: 11824


View Profile
« Reply #7 on: April 16, 2004, 10:34:15 PM »

i introduced the %encoded-folder% symbol as you proposed, but i don't understand why you used a loop to do it.
that's how i did
Code:
// build up base table
table:=NIL;
addArray(table, [
  '\n', CRLF,
  '%timestamp%', DateTimeToStr(now()),
  '%version%', VERSION,
  '%uptime%', uptimestr(),
  '%folder%', includeTrailingChar('/', decodeURL(folder.url())),
  '%encoded-folder%',
    encodeURL(includeTrailingChar('/', decodeURL(folder.url()))),
  '%parent-folder%',
    encodeURL(includeTrailingChar('/', decodeURL(folder.parenturl())))
]);
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!


Google visited last this page May 17, 2012, 12:36:24 PM
anything