• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

dynamic file viewer

 
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello there!

I've problem with my app, I don't know how to create dynamic structure of files on web using visual server pages (netbeans).

First thing that I wanted to implement it's to make table that holds all names of files and links to them, but it's really last thing that I wanted to achieve. There is no other option for that? like it was in php? dynamic code - for example if I've 5 files in folder this application just show me list of files with automatic hyperlinks? or I suppose to throw away visual page and create normal jsp + servlet with loop? how to deal with visual page in that case?

thank you
 
Ranch Hand
Posts: 2458
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If those files are exposed public, you need to enable directory browsing in the appserver configuration. Most appservers have it by default enabled. Consult the appserver's documentation for details.

About that "like it was in PHP", that is in any case also a webserver configuration setting. Apache HTTP server also supports that stuff.
 
Walter Krawiec
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Bauke Scholtz wrote:If those files are exposed public, you need to enable directory browsing in the appserver configuration. Most appservers have it by default enabled. Consult the appserver's documentation for details.

About that "like it was in PHP", that is in any case also a webserver configuration setting. Apache HTTP server also supports that stuff.



ok, but how to demonstrate files on web? files are not static..., I can read them by dir command but there suppose be method to show this names on web created in automatic way (all components in visual web page are fixed to layout).
 
Bauke Scholtz
Ranch Hand
Posts: 2458
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Walter Krawiec wrote:visual web



OK, if you aren't looking for public directory browsing (something similar this), but for embedding a table in your webapp, then you can just go ahead with the java.io API and some tabular component.
 
Walter Krawiec
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, table will be the best solution in this case. Thank you 4 so quick answers.

all the best

Walter
 
Brace yourself while corporate america tries to sell us its things. Some day they will chill and use tiny ads.
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic