ResourceSpace Mobile Web App
Download the zipped file. Extract all files (except the license.txt & readme.txt file – but not a problem if you do load these) to your ResourceSpace main directory. A simple drag & drop works. Don’t worry, we have not replaced any files!
This checks to see if a user is on a mobile device, and then sends them to the Mobile Search page with the latest results displayed.
Open your index.php file and find these 2 lines around line 9-10:
$topurl="pages/" . $default_home_page;
if ($use_theme_as_home) {$topurl="pages/themes.php";}
if ($use_recent_as_home) {$topurl="pages/search.php?search=" . urlencode("!last".$recent_search_quantity);}
Replace with this code:
// ADD MOBILE DETECT
$is_mobile = 0;
include_once("/pages/m/mobile_detect.php");
$detect = new Mobile_Detect();
if($detect->isMobile())
$is_mobile = 1;
else
$is_mobile = 0;
if($is_mobile)
$topurl= "pages/m/search.php?search=" . urlencode("!last".$recent_search_quantity);
else{
$topurl="pages/" . $default_home_page;
if ($use_theme_as_home) {$topurl="pages/themes.php";}
if ($use_recent_as_home) {$topurl="pages/search.php?search=" . urlencode("!last".$recent_search_quantity);}
}
The program should work by now – go ahead and load it on your mobile device to see!
We made a new folder located in YOUR_RS_PATH/pages/m. (Replace YOUR_RS_PATH with the location you saved your RS installation in.) Go ahead and browse to this folder with your FTP Program and you’ll see the files we’ve included. At this point, the modification is very small, with only the ability to search for content, view videos, view photos, and listen to audio. What more could you want though, right?
The files should be self explanatory by their names. We are using some custom Javascript code for the menus, and then we used the Jquery Mobile library to make everything mobile. We have included the custom javascript in case you want to change anything, and everything else is hosted from CDN servers.
While in the new ‘m’ folder, open up each file and do a Search & Replace. Replace any instance of “resourcespace.org” with your link. Also, we have quite a few links in the menu area. This is simple html and should be easy for you to have the menu go where you want. We’ve included what we feel are the most common navigation links, but you are free to change whatever you wish here.
Inside the Header file, you’ll notice a title that says “ResourceSpace”. The Footer also has a Copyright for HardMagic Publishing. Rebrand these to your company appropriately.
We have dynamic code setup using VideoJS. Showing video on a mobile device is rather pointless unless you have our HTML5 Video Plugin or if you designed one yourself. Simply alter the code found in flv_play.php and it will change how the program uses video. We gave you a list of variables at the top of the page so you can plug these in wherever you want.
This is not an easy feat to enable HTML5 Video, so we suggest you either have a great programming staff or hire someone to do this for you. Our team is available for this. Contact us if interested.
The main thing our customization does is to automatically convert your video into three formats. If you want to upload video manually, you can do so by uploading alternative files in these formats:
FLV, MP4, OGG. Resourcespace automatically creates a FLV file, natively. We suggest you encode your file in MP4 Format and upload it, then do another render in OGG format. If you only want iPhone support – it accepts MP4 Format, which you’re probably encoding with anyway with popular programs like Premiere Pro and Final Cut. Simply upload this as an alternate file and our plugin automatically detects and displays the right format for each device.
If you don’t have any video footage, but just want to check if it will work, look at the commented out lines we have in the flv_play.php file. This has a sample clip from VideoJS website to test your code.
Our plugin also supports WebM format, but we decided not to include that. You can look at the beginning of the file to see how we included other formats. It would be very easy to add WebM, but we don’t recommend this as it is not a popular format yet.
Click on the photo and your audio will start playing. We’re using the native Audio player for HTML5 so each browser will detect and display different controls. We do have a fancier version available for purchase if you’re interested and with enough support will be including this in a future release of this plugin.
If you want your audio to be HTML5 compatible, simply upload an alternative file in OGG format. The mp3_play.php file we included will automatically search for this file and display it on browsers that require OGG format.
If you are experiencing difficulty, please post your question in our Discussion Board.
You may alternatively ask the ResourceSpace Community for help on this topic at: https://groups.google.com/forum/?fromgroups#!topic/resourcespace/wrjmnkvWMdk
Some common areas people have had issues in, is not having the following variables set in their config.php file:
$use_resource_column_data = false; $use_watermark = false; $display_collection_title = false;
Check back for future versions of this plugin!











Over the course of 2010, we will be accepting short stories from aspiring authors at universities across the country. All the information on this is found right here. We will be publishing a book in 2011 with 24 short stories we pick from over 800 Universities. This means over 20,000 students will have access to participate in our contest. 


