Code solutions to PHP, JS, CSS

Spread your code soluces to the world

Love me

Search results for : load    (9)

Sound effects on an action with HTML5 (javascript)

HTML5 has simplified the handling of multimedia files. The simple tag audio replaces the couple object embed with param. A single line of code is sufficient and it is controllable with javascript. In the example below the onmouseout is used to refresh the source of the audio file. In addition to the preload attribute, you can use in the same...
solucior.com/33-Sound_effects_on_an_action_with_HTML5.html

Load image with page scroll.Lazy loading (javascript)

Images are displayed only when they are in the visible area of the window (lazy loading). The code work with the page scrolling. You dont need to modify your HTML code. You can replace the favicon.gif by a blank gif/png.
solucior.com/40-Load_image_with_page_scroll_Lazy_loading.html

Very simple drag and drop upload form (javascript)

There are many solutions and scripts for drag and drop upload. Here is a very simple solution using the native drag and drop of the modern browsers type file input. It is also compatible with browsers that do not support drag and drop as smartphone because it uses conventional HTML forms input. Tested with Safari, Chrome, Firefox last...
solucior.com/41-Very_simple_drag_and_drop_upload_form.html

Extract images from a page (php)

Getting all IMG sources and ALT from a local or remote page that returns an array. This function uses the DOM API from PHP 5. get_i( file ) = array( att, value )
solucior.com/26-Extract_images_from_a_page.html

Extract links from a page (php)

Getting all A HREF links from a local or remote page that returns an array. This function uses the DOM API from PHP 5. get_a( file ) = array( att, value )
solucior.com/25-Extract_links_from_a_page.html

Make dir and upload files via FTP (php)

These two functions simplify the creating directory and files upload by FTP in PHP.
solucior.com/10-Make_dir_and_upload_files_via_FTP.html

Dynamic image resizing according to location (javascript)

This javascript method resize image according to its location in the page. Images do not overflow the page or div that contains them. It works automatically, it is not necessary to modify the HTML content of the body. Implementation : • copy the javascript code in the header, between <head> and </head> • In the body...
solucior.com/19-Dynamic_image_resizing_according_to_location.html

Force file download (php)

Function that forces the files download. Sending the file size does not work in all configurations.
solucior.com/24-Force_file_download.html

Automatically adjust brightness contrast of an image (php gd image)

This script adjusts the brightness and contrast of an image using PHP5 and the GD2 library. Set the variable $url_img with the path of your initial image. You can change the variable  which corresponds to the size of the working image of the script.
solucior.com/5-Automatically_adjust_brightness_contrast_of_an_image.html