Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6342583
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T20:16:02+00:00 2026-05-24T20:16:02+00:00

I have been playing around with my phonegap app in eclipse using android sdk

  • 0

I have been playing around with my phonegap app in eclipse using android sdk and trying to figure out how to show dynamic html pages from a server’s DB in a phonegap application.

What I want to accomplish is;

to have a web page for example http://www.demo.com/login and the phonegap application will login to that web page and will show http://www.demo.com/dashboard.html and so it will take photos, access to build in gps etc..

Is it possible that phonegap application can be use like a web browser and display dynamic html pages and as well as have access to the native functions? Do I have to run a web service that the phonegap application will get and post json objects using that web service and then render the html code with the help of a js called mustache.js or whatever?

I really appreciate your help

Thanks a lot

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T20:16:04+00:00Added an answer on May 24, 2026 at 8:16 pm

    You can use PhoneGap with PHP and jQuery Ajax to get content. Load jQuery library at file head. At function onBodyLoad(), put the Ajax call for the PHP file:

    $('#content').load('http://www.example.com/test.php');
    at the HTML session, put the div id=”content” where do you want to show content.

    PHP:

    for($i=1; $i<=10; $i++) {
        echo '<p>Dinamic content coming from test.php! Value: ' . $i . ' of 10.</p>';
    }
    

    HTML will print:

    <p>Dinamic content coming from test.php! Value: 01 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 02 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 03 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 04 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 05 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 06 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 07 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 08 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 09 of 10.</p>
    <p>Dinamic content coming from test.php! Value: 10 of 10.</p>
    

    To send content to another page and log the user in, you can something like

    $.get('login.php?name=user', function(data) {
        $('#content').html(data);
    });
    

    And your login.php could have something like:

    if (isset($_GET['name'])) {
        $name = $_GET['name'];
        echo "Name: $name";
    } else {
        echo "Please enter a valid name!!";
    }
    

    To make your login secure, you might use the POST method, as described below:

    $('#form').submit(function() {
        $.post('login.php', $('#form').serialize(), function(data) {
            $('#content').html(data);
        });
        return false; // to avoid page going to login.php file
    });
    

    And login.php

    if(!empty($_POST)) {
        $user = $_POST['name'];
        $pass = $_POST['password'];
        // db query and stuff goes here...
        echo "Worked!";
    } else {
        "Enter values!";
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been playing around with the MVP pattern using winforms for the last
I have been playing around with the postgresql.conf file for a couple days now.
I have been playing around with the EF to see what it can handle.
I have been working with PostgreSQL, playing around with Wikipedia's millions of hyperlinks and
Have been playing around with linq but there is one thing I cant seem
I have been playing around with writing some simple card games in Python for
I have been playing around in expect recently and I for the life of
I have been playing around with a search control and i have noticed that
I have been playing around with Python's FTP library and am starting to think
I have been playing around with the MS Source Server stuff in the MS

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.