CodeIgniter + PhoneGap...

364 views
Skip to first unread message

Michael Cabus

unread,
Apr 19, 2014, 4:29:11 PM4/19/14
to phon...@googlegroups.com
Hi
  I have written an app using CodeIgniter...

I want to get at local mobile features like adding things to the calendar..

Can I use both PhoneGap and a PHP framework, like CodeIgniter?

Thanks so much,

Michael

Steve Husting

unread,
Apr 24, 2014, 1:22:47 PM4/24/14
to phon...@googlegroups.com
You can't use PHP files within PG because PHP is a server-side language and there is no server in PG to parse PHP.

aloto...@gmail.com

unread,
Apr 24, 2014, 2:12:00 PM4/24/14
to phon...@googlegroups.com

Too bad; so data intensive apps need to be native; makes sense.

Thanks 
Sent from my iPhone
--
-- You received this message because you are subscribed to the Google
Groups "phonegap" group.
To post to this group, send email to phon...@googlegroups.com
To unsubscribe from this group, send email to
phonegap+u...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/phonegap?hl=en?hl=en
 
For more info on PhoneGap or to download the code go to www.phonegap.com
 
To compile in the cloud, check out build.phonegap.com
---
You received this message because you are subscribed to a topic in the Google Groups "phonegap" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/phonegap/Pxp6B5mzAm8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to phonegap+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Greg Allensworth

unread,
Apr 24, 2014, 3:23:42 PM4/24/14
to phon...@googlegroups.com
Data intensive apps can be done in Cordova.
But you can't write them in CodeIgniter or other PHP frameworks.

You could use CI/PHP on the web server to generate your dataset in JSON
format, and have the Cordova app load it via AJAX. Tthe Cordova app
would query via network, to your custom endpoint.

Or you could use CI/PHP on the web server (even if that's localhost on
your PC) to generate your dataset and dump it to a JSON file, then
download and copy that JSON file into your application's "www" folder,
and load it via a typical <script> tag:
<script src="dbdump.json"></script>

Or you could do a hybrid approach: Have a CI/PHP endpoint which
generates a JSON dump, have your app capable of downloading and saving
this to a file via the File and FileTransfer APIs, and have your app
load from the on-phone database file. This way gets you flexibility to
work offline, and to fetch a new version of your DB via web.

So in my opinion, there's plenty of room for CI/PHP in your app's
development... just not ON the phone.

-g


On 4/24/2014 11:12 AM, aloto...@gmail.com wrote:
>
> Too bad; so data intensive apps need to be native; makes sense.
>
> Thanks
> Sent from my iPhone
>
> On Apr 24, 2014, at 1:22 PM, Steve Husting <shus...@aeteam.net
> <mailto:shus...@aeteam.net>> wrote:
>
>> You can't use PHP files within PG because PHP is a server-side
>> language and there is no server in PG to parse PHP.
>>
>> On Saturday, April 19, 2014 1:29:11 PM UTC-7, Michael Cabus wrote:
>>
>> Hi
>> I have written an app using CodeIgniter...
>>
>> I want to get at local mobile features like adding things to the
>> calendar..
>>
>> Can I use both PhoneGap and a PHP framework, like CodeIgniter?
>>
>> Thanks so much,
>>
>> Michael
>>
>> --
>> -- You received this message because you are subscribed to the Google
>> Groups "phonegap" group.
>> To post to this group, send email to phon...@googlegroups.com
>> <mailto:phon...@googlegroups.com>
>> To unsubscribe from this group, send email to
>> phonegap+u...@googlegroups.com
>> <mailto:phonegap+u...@googlegroups.com>
>> For more options, visit this group at
>> http://groups.google.com/group/phonegap?hl=en?hl=en
>>
>> For more info on PhoneGap or to download the code go to
>> www.phonegap.com <http://www.phonegap.com>
>>
>> To compile in the cloud, check out build.phonegap.com
>> <http://build.phonegap.com>
>> ---
>> You received this message because you are subscribed to a topic in the
>> Google Groups "phonegap" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/phonegap/Pxp6B5mzAm8/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> phonegap+u...@googlegroups.com
>> <mailto:phonegap+u...@googlegroups.com>.
>> For more options, visit https://groups.google.com/d/optout.
>
> --
> -- You received this message because you are subscribed to the Google
> Groups "phonegap" group.
> To post to this group, send email to phon...@googlegroups.com
> To unsubscribe from this group, send email to
> phonegap+u...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/phonegap?hl=en?hl=en
>
> For more info on PhoneGap or to download the code go to www.phonegap.com
>
> To compile in the cloud, check out build.phonegap.com
> ---
> You received this message because you are subscribed to the Google
> Groups "phonegap" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to phonegap+u...@googlegroups.com
> <mailto:phonegap+u...@googlegroups.com>.
> For more options, visit https://groups.google.com/d/optout.


--
Greg Allensworth, Senior Web GIS Developer
BS A+ Network+ Security+ Linux+ Server+

GreenInfo Network - Information and Mapping in the Public Interest
564 Market Street, Suite 510 San Francisco CA 94104
PH: 541-223-7636 email: gre...@greeninfo.org
Web: www.GreenInfo.org www.MapsPortal.org

Subscribe to MapLines, our e-newsletter, at www.GreenInfo.org

jcesarmobile

unread,
Apr 25, 2014, 2:42:44 AM4/25/14
to phon...@googlegroups.com
It's not a question about hybrid VS native, PHP is a server language, you can use it only on the server, if your app is native you build it with objective-c or java, if you app is hybrid you build it with html, css and javascript, there is no room for PHP on the client. You use PHP in your server, you can use the same server for hybrid or native apps.

As Greg said, your server should provide a JSON or XML and an webservice to get them through XHR calls
Reply all
Reply to author
Forward
0 new messages