rhomobile

Showing a View on a button click in rhoMobile

时光毁灭记忆、已成空白 提交于 2020-01-15 11:10:50
问题 I have created a simple project in rhomobile. My home screen shows a text box and a button. here is the code for that in index.erb <div data-role="content"> <br /><br /> Email Address : <input type="text" name="Email" /><br /> <form method="POST" action="<%= url_for(:action =>:show_VibLoc) %>"> <input type="submit" value="Submit" /> </form> Now I have created a new file VibLoc.erb in settings folder which is under app folder. in VibLoc.erb i am showing just two buttons. In the controller.rb

rhomobile and oauth2

一世执手 提交于 2020-01-06 19:30:51
问题 Based on this stackoverflow question foursquare oauth2 for IOS I need to send user from my app to foursquare. Get permission and redirect to my web server. I get the access token, but how do I redirect to a view? In my rhomobile controller I have def fsq_login WebView.navigate('https://foursquare.com/oauth2/authenticate?client_id=MY CLIENT_IT&response_type=code&redirect_uri=http://lvh.me:3000/fsq_req') end Once I have the access_token, how can I get my webserver to trigger a rhomobile view?

RhoMobile initial database

瘦欲@ 提交于 2020-01-06 14:19:56
问题 Is there a way to setup initial data in a database when using RhoMobile framework? It is using sqlite database as I see. Is there a way to add a preset sqlite file to the project and make it built in the application bundle? 回答1: You can seed the database with a flat file containing the initial data, through the use of the Rho::RhoUtils.load_offline_data method. Full documentation here. 来源: https://stackoverflow.com/questions/7836527/rhomobile-initial-database

RhoMobile initial database

浪尽此生 提交于 2020-01-06 14:19:32
问题 Is there a way to setup initial data in a database when using RhoMobile framework? It is using sqlite database as I see. Is there a way to add a preset sqlite file to the project and make it built in the application bundle? 回答1: You can seed the database with a flat file containing the initial data, through the use of the Rho::RhoUtils.load_offline_data method. Full documentation here. 来源: https://stackoverflow.com/questions/7836527/rhomobile-initial-database

How to access database and create table in Rhomobile framework

做~自己de王妃 提交于 2019-12-25 01:39:38
问题 I am new to Rhomobile. I am developing application in Rhomobile. Can any one guide me How can view the database and tables in RHOMOBILE and How can create a database and tables. I have seen the RHOMOBILE tutorials. I did't get any clear idea. Pleas Guide me. 回答1: If in Windows you can view your database in the file under your gem's folder in the path platform/wm/bin/win32/rhodes/Debug/rho/db/syncdblocal.sqlite You can use SQLite Database Browser (http://sqlitebrowser.sourceforge.net) to

How to pass variables to partial in Rhomobile

≡放荡痞女 提交于 2019-12-24 16:33:09
问题 I have a partial where i need show the value of variable catchedEvent , Partial <div class="eventList">Here to show the value of the variable</div> On my erb page i'm calling this using <%= render :partial =>"mypartial" %> I can't get the way to pass the variable to it. Please help. 回答1: You can use the locals or collections as specified over here http://docs.rhomobile.com/rhodes/ui#advanced-usage-of-render <%= render :partial =>"mypartial", :locals => { :event => "myevent" } %> Then on

Opening Camera Instance from a Web App

僤鯓⒐⒋嵵緔 提交于 2019-12-23 05:14:25
问题 Is it possible to open Camera instance from Web App? I have a Web App. displays something, and I want the user to be able to Take a picture and send it to the server. How can I achieve this? 回答1: Using cordova apis it's easy Check out the following code sample: JS: // A button will call this function // To capture photo function capturePhoto() { // Take picture using device camera and retrieve image as base64-encoded string navigator.camera.getPicture(uploadPhoto, onFail, { quality: 50,

Alternative ways for developing for Android

巧了我就是萌 提交于 2019-12-23 04:29:43
问题 I am an Android developer. I know of a few cross-platform development tools such as Rhomobile Anscamobile's Corona SDK Phonegap Titanium Appcelerator Google App Inventor. If you know any tools apart from the ones I have listed please reply. Thanks in advance. 回答1: Of course there is Monodroid... 回答2: Sencha Touch 回答3: Air for Android Monodroid Android scripting http://google-opensource.blogspot.com/2009/06/introducing-android-scripting.html 回答4: App Inventor is fun. This is what I have 回答5: