ive got a website im running from a server lets called it LinuxServer.
this website is basically a very complex ordering system and ive probably coded the best part of 70,000 lines of code in it.
One thing our old system did was print barcodes, and this was done in vb, calling a .bat file.
The .bat file contained:
certainprogramname.exe adynamicfilename.txt \\print commands
so VB would run it, send the dynamicfilename to the certainprogram.exe and the print it to our barcode printer, job done. but now because ive developed this new system ive had to change it.
i understand the difference between client side and server side processing etc, and from my php/js/apache system ive done the following.
the js on my webpage creates certain strings, which get passed (mvc) to my php function. My php function creates the dynamictextfile and the .bat with the dynamic info in, job done.
Ive set up a share on our linux server via smb to our windows client pc(the one with the barcode printer attached to) so thats all good, basically as a temp /home/barcodepc is actually a windows pc named barcodepc with a share on. this is fine and works as expected (php file creates file, then copies it to the windows pc).
now my huge issue..
This .bat file has to be run from the client pc, because it runs the program.exe before it prints (as far as im aware it does anyway). so i need some way to be able to run that .bat file, as if its running or is actually running on the client pc, but i need to be able to call it from js, php or similar.
Initial ideas have been java applet(dont want to do this), another idea is perhaps somehow send the details to that printer(set up a printer share) but the issue remains about it cant call the program.exe then.. i think, and another idea is set up a type of cronjob/scheduled task on the windows pc to check for a new file every minute(if so, print it - not ideal..)
sorry for the long post but thought its best to explain the whole thing/limitations.
thanks in advance and ideas muchly appreciated.