Hi people!

I want to program a cgi that outputs only the necessary data for a big tree in a webpage. This tree is big enough that it is not worth trying to download the entire contents of the tree at each click on it.

Now there is a possibility to output only the necessary (open) nodes. But it gets complicated also, especially when you want to use images at beginning of nodes. One thing is for sure that it should download each different image only once, and not for every open node the same image again.

Now this could be done in cgi, i hope:tongue:

Another way is maybe to make use of systree common control.
Take a look at this html code:

<HTML>
<frameset cols="280, *" bordercolor="#FFD500" name="leftright" frameborder="yes" border="2" framespacing="2">
<frame src="c:\" scrolling="yes" name="lefttext" marginwidth="0" marginheight="0">
<frame src="c:\" name="righttext" marginwidth="0" marginheight="0">
</frameset>
<noframes></noframes>
<BODY bgcolor="#FFFFFF">
</BODY>
</HTML>


Because explorer.exe and iexplore.exe are not that different under windows and explorer makes use of systreeview/listview. I personally think that this last way to do it is the best but HOW to do that i really don't know, and don't have enough experience with cgi's.

If you are thinking these methods of solving this big tree problem are the right one, i'll try to implement.

Hope you have some smart ideas or tips on how to implement:alright:
Posted on 2002-08-06 05:44:59 by eisodur
Sorry for not responding to this earlier. I rarely view this forum. Anyway back to the main question. Honestly, I don't know how to create a tree view control using CGI but I do believe it's possible. If you take a look at microsoft's website especially MSDN the columns on the left looks like a treeview clone. But here's the best I could do as of the moment.

Tested on Windows 2000 SP2 - Apache 2

P.S.: Wow!!! I think this is my first thread on this forum. :)
Posted on 2002-08-11 01:45:26 by stryker
Hi, stryker !
Your program seems to me very interesting but under Win98Se it only starts ... and then stops without any results. What must I see in 2k ?
Mike
Posted on 2002-08-16 05:25:32 by Mike
under Win98Se it only starts ... and then stops without any results

Are you double clicking this program? a websever runs a cgi program by creating a process of the program with it's standard output directed trhu the webserver to a user's web browser so just opening a cgi program shouldn't show any output. If you don't have a webserver set up and want to see the output of a cgi program I guese you could re-link it to run in console mode.
Posted on 2002-08-16 05:43:33 by Kudos
Now, after relinking fo console mode, I type "command" and then (in console)
I type "cgitreeview"; that's output (the same in 98se and 2k):

*********************************************************************************
Content-type: text/plain

<html><head><title>ASM CGI :: Treeview</title></head><frameset cols="280, *" bor
dercolor="#FFD500" name="leftright" frameborder="yes" border="2" framespacing="2
"><frame src="file:///c:/" scrolling="yes" name="lefttext" marginwidth="0" margin
height="0"><frame src="file:///c:/" name="righttext" marginwidth="0" marginheight
="0"></frameset></html>
*********************************************************************************

When I insert output of the program into file 1.htm
*********************
<html>
<head>
<title>ASM CGI :: Treeview</title>
</head>
<frameset cols="280, *" bordercolor="#FFD500" name="leftright"
frameborder="yes" border="2" framespacing="2">
<frame src="file:///c:/" scrolling="yes" name="lefttext"
marginwidth="0" margin height="0">
<frame src="file:///c:/" name="righttext" marginwidth="0" marginheight="0">
</frameset>
</html>
*********************
it opens in Internet Explorer and shows me my disk C:


Is it all that can do this program? What webserver must I set up ? Why this program
cant show me the same?
Mike.
Posted on 2002-08-16 10:39:19 by Mike
Do you have a webserver? I used apache 2 on win2k then type this on the address bar:

http://localhost/cgi-bin/filename.exe assuming you have setup everything perfectly. Try searching the forum for asm cgi there are threads that discussed this issue.

Is it all that can do this program?
Yes, the original poster asks a question on how to create an ASM CGI with a treeview style. Since I don't know how to do the treeview, I chose to give an example on how an ASM CGI is done. Which basically, solves a part of the original posters problem.
but HOW to do that i really don't know, and don't have enough experience with cgi's.


:)
Posted on 2002-08-17 17:57:58 by stryker
I download apache from www.apache.org and install it in Win9x. There are no some changes and exept all it have no uninstall. Is there other web servers?
Posted on 2002-08-18 08:21:12 by Mike
There is a web server that comes with windows 9x (at least my version of 98 had it) called personal web server wich u can install by going to add remove program/windows setup/internet tools. This might be ok for testing but I don't think it would be good to use this.
Posted on 2002-08-18 08:55:49 by Kudos
O-o-o!
After instaling in Windows2000 "Web-server" and "Web-dispatcher" I see only black screen with running text. That's all. But what's interesting. I've see one cgi from my buddy, he write all in visual C. One executable (it's size=265K) show more than 20 cgis in graphical interface (as Internet Explorer). This program works in any Windows WITHOUT INSTALLED WEB SERVERS !
Mike
Posted on 2002-08-19 10:43:09 by Mike
This program works in any Windows WITHOUT INSTALLED WEB SERVERS !
Really? I would love to see this CGI in action. Where can I download it or test it? Or is this just an emulation? Or your friend coded a browser that acts as a WEBSERVER...There are other possibilities that CGI can run and its not only through webservers...

You can route File I/O operations when cgi's are run under your own browser... parse it...
Posted on 2002-08-19 11:33:39 by stryker
I want to see it too but he don't give it. All that buddy sayd me is: this program gets cgi and then show; he use it not only for debugging; he write it in C++. I have seen it, graphics in it looks sometimes worse than in IExplorer but commonly are very pretty...
Mike
Posted on 2002-08-20 08:25:38 by Mike