I'm working with SmartOptimizer: minify js and css, use css data uris, add far expire headers and other features. (http://farhadi.ir/works/smartoptimizer) It works fine, but i don't know if exists a similiar application with similar or best tools (like Google Closure, CSScaffold,..)
If you're not sure witch is better, what's your favourite??
Thanks for reading, sorry for my english
YSlow ( http://developer.yahoo.com/yslow/ ) will tell you where you can optimize, at least, though it won't solve your problems for you.
WEB optimizer(http://webo.name/) is a great thing. It can not only find issues, but also do some optimizing. However it isn't free for commercial use.
I have a JS and CSS compressor into my editor (Coda.app), and I optimise images with ImageOptim.app. You just have to drag & drop the images, and the app does his job by choosing the best compression throwing it at multiple images libraries.
Note: MAC only
Related
I need to select multiple files and I found one way to do this. But that way only works on newest browsers, using attribute "multiple" on input.
I didnt found any solution on internet.
Can anyone help me to find a solution?
I'm able to use HTML, PHP, JavaScript (jQuery).
Thanks for attention.
There is no native solution to multiple file selection uploading in older browsers. This requires some kind of plugin technology, typically Flash or Java.
I personally use Plupload. It will seamlessly switch between HTML5 and Flash (among others) based on the user's browser. There are plenty of other Flash or Java multi-file upload solutions out there as well.
I think the traditional solution to this is to allow multiple file input elements; like this.
File 1: [_____] (Browse...)
File 2: [_____] (Browse...)
Upload more files...
If the user needs more, just have them click a button at the bottom to create them. At some points, YouTube would allow you to use a Java applet-based upload dialog as well; but since then the opinion of Java applet security has faded quite a lot and most people avoid it entirely.
Having multi-selection is a real benefit to modern browsers, and one that's not really so easy to emulate in the older ones.
Living in 2012 I did not think a image upload using PHP would cause so many difficulties.
My requirements are:
multiple file upload
cross-browser functional
considering security issues
depending on the least possible add ons or extensions
supporting drag&drop (would be nice, at least)
The options to be available seem to be to me:
simple single file upload (or several single file inputs, but you still have to select each image manually) using PHP (and e.g. GD library) only
(+) Pros: fully cross-browser functional, not depending on neither flash, nor javascript, nor html5, nor any add ons etc., maximum of customizability
(-) Cons: bad user experience as no support of multiple files, no drag & drop etc
a compromise, using e.g. jquery
as promoted on many posts and other sites, seen this link, e.g.: http://blueimp.github.com/jQuery-File-Upload/
(+) Pros: supporting multiple file uploads and even drag and drop besides other nice features for mostly only FireFox, Chrome, Safari (see link for details)
(-) Cons: only single selecting files and no drag & drop for IE (tested on IE6-IE8 by myself)
HTML5: browser market shares don't seem to allow to depend on HTML5 only, still...
Flash: I found many different uploaders based on flash, but when testing, many did not fulfill what they claimed (e.g. select multiple files and cross-browser functionality). Two examples I found useful:
http://www.uploadify.com/demos/
http://code.google.com/p/swfupload/ (see http://demo.swfupload.org/v220/ for Demos)
(+) Pros: those mentioned supporting multiple file uploads
(-) Cons: no drag and drop, depending on Flash add on, and I am not a security expert nor very familiar with flash, but the documentation of swfupload e.g. states they cannot/do not check the Mime-Type of uploads and totally rely on checking the file extension)
However, I found statements that e.g. google docs uses multiple file upload not based on flash but still working in IE too. Has anybody an idea how they do that?
My other questions were: did I oversee an opportunity? Are those all of the better options available? Is there any non flash-based way for at least multiple file upload working in IE (at least v8) too? How do you guys do it? Or is it really waiting and hoping for the breakthrough of HTML5 and now having 5 different uploaders, each optimized for a special browser/add on availability?
Thank you very much in advance!
It looks like you did your research pretty thoroughly. I discovered a similar conundrum back a few weeks ago. As for the Google Docs ref, I would really like to see that because I have never found anything like that. Personally if your dealing with a younger audience for your site I would recommend using the jQuery option and displaying a browser recommendation of Firefox or Chrome to IE users. Go Flash for the older crowd that will be more likely to be on IE.
Unfortunately there is no winner here really that I have found. But at least with the jQuery option you avoid Flash AND have the potential that IE will work with it in future versions. With HTML5 Flash is quickly disappearing (and good riddance). Now if that would only happen with IE. I mean come on, how is it that even in IE9 they don't even come close to their competitors at being standards complaint??? Its just ridiculous.
is thier a guideline of how i can deal with playing around with audios and recording webcams, and what file formats i should use for optimisation, and plus any poplaur modules, plugins and classes that i can use to prevent re-inventing the wheel. im really looking at using this kind of stuff for user generated content. basically im looking for good advice, on how i should deal with kind of stuff? thanks :)) sorry for the broad question?
Take a look at red5. It's a flash streaming server which can record and play back webcam streams. There are also commercial alternatives such as Wowza Media Server and Adobe Flash Media Server. All of these are flash based though. I don't know of any HTML5 based approaches.
I'm working on a biology web based application and trying to figure out what language to use. The features I need to include are:
Image viewing frame - This area will display the current image that the biologists wish to see. The application needs to take in a number of coordinates from a file and draw those points on the image displayed here. When the biologist wishes to change images there needs to be no flickering from the refresh. Will do this using multiple image buffers probably. Content needs to be scrollable and able to be zoomed in.
There need to be labeled buttons that advance, step back, zoom, and play the images displaying in the image frame. There also needs to be some type of list view where images titles can be selected to be displayed.
There will be a bunch of folders of images on the server that can be selected from. The application must allow the user to select which folder of images to be loaded. It also must be able to read from either an txt or xml file and visually display the information there by way of line graph.
Would like to be able to run scripts on the server from the application.
I feel that all these things are doable by a web application but I have no idea what language to use. Most people recommend php, but i don't want to delve deeper until I know what its limitations are. Any suggestions are welcome. Thanks in advance.
-Mike
PHP can do everything you need for the back end, but most of the stuff that you describe is UI based, and this is dependent on the client, which is, of course, the browser. For highly graphical projects, you can do a lot in JavaScript and some JavaScript libraries have a lot of these capabilities built in. You might also consider Flash or Flex.
You might even consider a desktop application that runs outside of the browser. You can use Java, which is easy to deploy, but still requires the user to have the Java Runtime Engine, or you could go with a language that you can compile down to a native application.
Regardless of the front end technology that you choose, you'll still need a back end, and PHP can handle this.
You will find almost every server side platforms such as php , asp.net, asp, etc will do all of the above.
PHP is a language that resides on the server and handles all requests. Javascript (and associated libraries) is a language which is executed by the client's browser and handles (almost) all interaction. PHP is definitely able to do what you want, but for the interaction stuff (particularly the zoom, scrolling, etc.), you'll also need to use Javascript.
So, short answer, PHP is good, but you're going to need to use client-side scripting as well.
PHP is more than capable of doing this. You are going to need to use it in combination with some Javascript to handle the client side effects you describe. I would look into modifying galerific for your needs and then whip up some javascript to write points over the images.
From your concerns about image refresh/flicker, it really sounds like a desktop app is what you are looking for, for a rapid response on image changes. The requirements on this really seem to need to be defined better before you can choose a language... PHP can do all the server side stuff you mentioned, but you might have a harder time getting the image viewing "frame" to provide the functionality you want.
Due to the image manipulation requirements it might be easier to go with something like flash with a php backend or asp.net with silverlight. It might be difficult to prevent flicker and delays with using pure javascript as opposed to flash/silverlight.
Image viewing frame
This will most likely need to be done on the client side using tools/frameworks such as jQuery, the canvas element, silverlight, or any of the other 100's that are out there.
There need to be labeled buttons that advance, step back, zoom, and play the images displaying in the image frame. There also needs to be some type of list view where images titles can be selected to be displayed.
PHP or any other server-side scripting language could pull this off. If this is meant to be a quick project running on free/cheap hardware then PHP would be a good choice. If the plan is a large application that will have to be maintained over the course of many years and hosting/price is not an issue then I would suggest something like ASP.NET
There will be a bunch of folders of images on the server that can be selected from. The application must allow the user to select which folder of images to be loaded. It also must be able to read from either an txt or xml file and visually display the information there by way of line graph.
Again any server side language could do the folder listing portion. As for reading files and creating graphs, this would most likely be a combination of server side and client side programming. jQuery for example, has plugins that could quite easily take a xml file and create a line graph.
Would like to be able to run scripts on the server from the application.
PHP, ASP.NET - both could do this. I'm sure many others could, but these are the ones i use most often
The issue with PHP is that quite often, the code turns into a mess over time. This is maybe not so much an issue with the language as the people using it and the purpose the app was built for (a quick, one time project). Classic ASP also has the same issues.
ASP.NET is a good combination of OOP programming that allows you to separate presentation from logic with minimal effort.
Has anyone any reources for learning how to implement SVG with php/mysql (and possibly with php-gtk)? I am thinking of making a top-down garden designer, with drag and drop predefined elements (such as trees/bushes) and definable areas of planting (circles/squares). Gardeners could then track over time how well planting did in a certain area.
I donĀ“t really want to get into flash...
I'm looking for a similar solution, and the two relevant questions here are Scripting SVG and Displaying vector graphics in a browser.
Neither of them give much hope, though, as each browser has different vector capabilities. Dojox.gfx appears to be a cross browser javascript graphics library which may do everything you need, but it won't necesarily do it in SVG. Canvas is gaining a lot of support and interest.
-Adam
Here's what I found I guess in some other question, not sure though.
raphael
It's a javascript library for working with svg.
There's an example, but try using browsershots to see if you are actually happy with the support of browsers (IE for example does not have native svg support).
Me personally have decided not to use svg, rather implement images + js solution as I don't think svg is supported enough nowadays.