rejetto forum

user sections via url

Guest · 10 · 6666

0 Members and 1 Guest are viewing this topic.

nermal

  • Guest
i use hfs for long time
and im starting to use the "user created symbols"
like [sym-somename] and calling it as %sym-somename%
and it is working just like the include in asp or php, but there feature that i want to ask
can we have the user created symbols to serve pages like the progress or the upload that are sections [progress] and [upload]
and we call it ~upload or ~progress

we could use this address operator to call some user section like the html files used in this post, instead the external html file, we could put it inside a single tpl file....
ex.: the wma.htm would become a section [sym-wma] and we could call it like ~sym-wma....


Offline Giant Eagle

  • Tireless poster
  • ****
    • Posts: 535
  • >=3 RAWR!
    • View Profile
    • RAWR-Designs.com

nermal

  • Guest
[anything_you_want.html]
<html codez go here>

link to it using:
http://%host%/~anything_you_want.html

:)

but this work only for the static content, the server side(the hfs symbols) dont work in this pages...like in this test...
i replaced the main section with this....

Code: [Select]
<html>
<head>
<frameset cols=200,*>
  <frame name=progress src="/~sym-sidemenu.html" scrolling=auto marginwidth=0>
  <frame src="~sym-main" scrolling=auto>
</frameset>
</head>
<body>
</body>
</html>

[sym-main]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
  <style type="text/css">
  %style%
  </style>
  <title>HFS %folder%</title>
  <link rel="shortcut icon" href="favicon.ico" />
</head>
<body>
%login-link%
%loggedin%
%upload-link%
<div id=folderlabel>folder</div>
<div id=folder>%folder%</div>
<div id=body>
%folder-comment%
%up%
%files%
</div>
<div id=footer>
<a href="http://www.rejetto.com/hfs/">HttpFileServer %version%</a>
<br />Servertime: %timestamp%
<br />Uptime: %uptime%
<br />Build-time: %build-time%
</div>
</body>
</html>

[sym-sidemenu.html]
<b>teste</b>


Offline ledufe

  • Tireless poster
  • ****
    • Posts: 272
  • LEandro DUpont FErreira
    • View Profile
    • http://ledufe.no-ip.info:2222
i never had used this thing before (the sym-section and the call to it in the address) but i just tested here and "nermal" is right, the %sym-name% work and it is being called right(http://%host%/~sym-name), but the symbols inside it no....

using the code posted here in this post, the test resulted in the same results.... not working....

it just print in the screen the symbols.... see the attached picture to watch it...
<<LeDuFe>>


Offline rejetto

  • Administrator
  • Tireless poster
  • *****
    • Posts: 13510
    • View Profile
you are trying to get the file list in [sym-main].

but what list do you expect it to show?


what files should i see accessing /~sym-main ?


Offline ledufe

  • Tireless poster
  • ****
    • Posts: 272
  • LEandro DUpont FErreira
    • View Profile
    • http://ledufe.no-ip.info:2222
sorry rejetto, i was thinking in use this kind of solution to make some of my oldest wish using hfs...
i was trying to make the hfs act/looks like some file-explorer(windows explorer) with the folder tree, and my idea was to only show the folders at the left frame and show only the files and links at the main frame, this is only a test, and i used the code of the other post....

tell me if you can't understant me.....
i will try to make myself more clear, later, im at work now, but i will test it and post my tests here...

but trying to show what i want, see this post...
i want to make this really work
like in this picture



http://www.rejetto.com/forum/index.php?topic=3800.0
« Last Edit: September 24, 2007, 07:40:17 PM by ledufe »
<<LeDuFe>>


Offline Giant Eagle

  • Tireless poster
  • ****
    • Posts: 535
  • >=3 RAWR!
    • View Profile
    • RAWR-Designs.com
The way you want it to be is do-able, requires some time, but could be done..

but.. you need JavaScript to achieve it.

HFS cant split the folders from the files, and you cant use 2 different templates at once.


marlonRJ

  • Guest
The way you want it to be is do-able, requires some time, but could be done..

but.. you need JavaScript to achieve it.

HFS cant split the folders from the files, and you cant use 2 different templates at once.

so...
how can it be done?
like explorer...



Offline ledufe

  • Tireless poster
  • ****
    • Posts: 272
  • LEandro DUpont FErreira
    • View Profile
    • http://ledufe.no-ip.info:2222
still trying here..
let you know when it done..
<<LeDuFe>>


Offline Mars

  • Operator
  • Tireless poster
  • *****
    • Posts: 2059
    • View Profile
i have test this:

create a new virtual folder or real folder
name it as you will by sample: test

put into advanced diff tpl 


<html>
<head>
<frameset cols=200,*>
  <frame name=progress src="/~sym-sidemenu.html" scrolling=auto marginwidth=0>
  <frame src="/~sym-main" scrolling=auto>
</frameset>
</head>
<body>
</body>
</html>

create a virtual folder into home directory and rename it  ~sym-main
right clic to the folder and hide it

put into advanced diff tpl


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0


Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
  <style type="text/css">
  %style%
  </style>
  <title>HFS %folder%</title>
  <link rel="shortcut icon" href="favicon.ico" />
</head>
<body>
%login-link%
%loggedin%
%upload-link%
<div id=folderlabel>folder</div>
<div id=folder>%folder%</div>
<div id=body>
%folder-comment%
%up%
%files%
</div>
<div id=footer>
<a href="http://www.rejetto.com/hfs/">HttpFileServer %version%</a>
<br />Servertime: %timestamp%
<br />Uptime: %uptime%
<br />Build-time: %build-time%
</div>
</body>
</html>



see your web page and select the directory TEST

html code as bug with frames
back button must desactivate frames created to work correctly

with javascript it is more easy to do what you want

« Last Edit: September 26, 2007, 10:25:19 PM by mars »