Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PERL/TK 1

Status
Not open for further replies.

1DMF

Programmer
Joined
Jan 18, 2005
Messages
8,795
Location
GB
I've dl'd the PERL/TK module and toolbar widget, uploaded them, run the toolbar.pl file which i assumed was a demo PERL script and nothing happens?

obviously it isn't as simple as this, how do I use TK and the toolbar widget for webapps?

any good resourses someone can point me to to start the learning process.

thanks

1DMF

"In complete darkness we are all the same, only our knowledge and wisdom separates us, don't let your eyes deceive you.
 
Tk doesn't run webapps. ;-) What you're thinking of is probably Java applets, or at the minimum, Flash objects (Java applets can create their own windows though whereas Flash requires a browser wrapper). Tk is for offline graphical user interface and doesn't go through to the end user in a web environment (although probably if your web server has a monitor hooked up, your admin is probably wondering why all these Tk windows keep popping up!)
 
OIC, I thought I could start creating some nice web apps with cool looking widgets, we use 3rd party hosting, so i'm not sure if their console was getting these popups -lol

So basically for web apps all I have at my disposal is X/HTML with PERL.

And I guess client side I need to harness JavaScript, does Flash/Java etc require a Flash/Java server/hosting to enable the front end to talk to the back end or can a Flash/Java front end talk back to my PERL backend?

"In complete darkness we are all the same, only our knowledge and wisdom separates us, don't let your eyes deceive you.
 
If you are going to learn something new, might as well be Ajax (asynchronous javascript and XML). Haven't tried it yet, but the forum forum1600 seems to be fairly active, and someone's just posted a couple of useful looking FAQs.

Steve

[small]"Every program can be reduced by one instruction, and every program has at least one bug. Therefore, any program can be reduced to one instruction which doesn't work." (Object::PerlDesignPatterns)[/small]
 
I already do use AJAX, very basic mind, I've been getting some great replies to my questions in the new Forum as well.

Tracey has written some cool FAQ's, I now know what JSON is :-) , but am strugling to to understand what a framework will do for me or if i need to adopt one, and if so which one!

I think I'll steer clear of Java, i'm still not very proficient in the languages i do know without delving into a heavy language like Java, I've been concidering sneding myself to colledge to learn Flash, I have MX studio , but have got no-where trying to teach myself, and revert back to notepad/PERL/Javascript & XHTML.

Also I'm not sure if i want to learn Flash if I cannot keep my PERL backend or need to purchase flash hosting!

I nearly switched to ColdFusion at one stage but that doeasn't help me with my front end (client side) coding, you see i'm rubish at drawing and need something to help make my front end look more professional, i've opted for buying a HTML template for my current re-write (man the code was rubbish and non-compliant from that site) but I guess you pay for the design not the code!

i want to re-write my members area side of things and make it feel more windows like, with a GUI instead of simple rollover mouse buttons etc... Is active-X a possibility?

But I guess that will be windows only platform if I do that, what would you use to make an interactive members area look and feel more like a GUI application than a web page?



"In complete darkness we are all the same, only our knowledge and wisdom separates us, don't let your eyes deceive you.
 
I'd say I'm fairly alright with Flash, but there's a lot of potential that it has that I'm not even aware of how to do. One way I know to get Flash to interact with Perl/CGI is to simply load variables from a CGI file, i.e.

Code:
on (release) {
   loadVariables ("/cgi-bin/processor.cgi?var1=" + var1 + "&var2=" + var2);
}

So basically that loads variables from /cgi-bin/processor.cgi?var1=...&var2=..., inserting current Flash variables into the query (you can use the POST method too, which I think causes Flash to automatically send every active variable into the CGI without having to manually type them, but I haven't done this kind of work in a long time).

And then the CGI file would print a text/plain response full of variables to put back into Flash:
Code:
var1=new value for var1&var2=another new value&var3=some new variables can be declared too

So in this way, it's similar to how you would use Ajax with JavaScript, calling a CGI file (possibly passing in variables for the CGI to deal with) and having the CGI return some stuff for the JavaScript to work with (in this case, more variables!)

So in this way, Flash can work fine on just about any server that would support CGI (but also note that Flash can't load variables from different websites than the one it's on by default, this is a security concern).

But like I said, Flash has a lot more potential to it, so perhaps there are more advanced methods which might require a specialized server.
 
Thanks Kirsle,

maybe Flash will be my next project then, to learn how to use it, develop in it and talk to PERL.



"In complete darkness we are all the same, only our knowledge and wisdom separates us, don't let your eyes deceive you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top