This question is locked. New answers and comments are not allowed.
Hi,
I built the functionality and framework for my mobile application using the MVC model prior to integrating with Kendo UI and therefore every action has it own php page. eg. view.php , delete.php, update.php, reply.php. I didn't realise that the Kendo UI Mobile would only work with one file using views. I had read that I can use remote views to link between pages but this doesn't seem to be working well for me. I have read the documentation but am not sure I fully understand it or even if its correct. Can anyone help with my navigation?
I have an index page as set out below:
I have a listall page which is has the same header and footer as above and then the different central part as set out below:
I have a view page as below:
My Issues are:
1) When I select th
2) On the listall page, I select a message in the list and this does not put the # in front of the URL. This takes me to the view page but does not have the styling of the application applied. Why is this?
3) When I select the back button its adds the #, this sometimes works and sometimes doesn't depending on what page Im on. How can I get it to work for all pages?
4) As the code from the different pages is being appended to the main index page, when I perform an action, this is executed multiple times and I only want it to perform the operation once.
Any help would be much appreciated.
I built the functionality and framework for my mobile application using the MVC model prior to integrating with Kendo UI and therefore every action has it own php page. eg. view.php , delete.php, update.php, reply.php. I didn't realise that the Kendo UI Mobile would only work with one file using views. I had read that I can use remote views to link between pages but this doesn't seem to be working well for me. I have read the documentation but am not sure I fully understand it or even if its correct. Can anyone help with my navigation?
I have an index page as set out below:
<
div
data-role
=
"view"
data-title
=
"Control Panel"
>
<
div
data-role
=
"header"
>
<
a
data-role
=
"backbutton"
>Back</
a
>
</
div
>
<?
php
if (isset($error)){ echo '<p
style
=
"color:red"
>Error: '. $error .'</
p
>';} ?>
<
ul
data-role
=
"listview"
data-style
=
"inset"
>
<
li
><
a
href
=
"messages/listall"
>Customer Messages (<?=$unread_messages?>)</
a
></
li
>
</
ul
>
<
script
>
var listView = $("#listView").kendoMobileListView({
pullToRefresh: true,
appendOnRefresh: true
});
</
script
>
<
div
data-role
=
"footer"
>
<
div
data-role
=
"tabstrip"
>
<
a
href
=
"index"
data-icon
=
"/mobile_kendo/"
>Home</
a
>
<
a
href
=
""
data-icon
=
"refresh"
>Refresh</
a
>
<
a
href
=
"settings"
data-icon
=
"settings"
>Settings</
a
>
</
div
>
</
div
>
</
div
>
<
script
>
var app = new kendo.mobile.Application($(document.body), {
icon: "URL to a web clip icon"
});
</
script
>
I have a listall page which is has the same header and footer as above and then the different central part as set out below:
<
div
data-role
=
"view"
data-title
=
"Control Panel"
>
<
div
data-role
=
"header"
>
<
a
data-role
=
"backbutton"
>Back</
a
>
</
div
>
<
h2
>Messages</
h2
>
<
table
>
<?
php
echo $unread_messages . ' - unread messages'; ?>
<
tr
>
<
th
>From</
th
><
th
>Intro</
th
><
th
>Date</
th
><
th
>Status</
th
>
</
tr
>
<?
php
foreach ($messages as $message):?>
<?
php
if ($message->isnew == 1){ ?>
<
tr
style
=
"font-weight:bold"
>
<?
php
} else { ?>
<
tr
>
<?
php
} ?>
<
td
><?=$message->customer_name?></
td
><
td
><
a
href="messages/view/<?=$message->id?>"><?=$message->message?></
a
></
td
><
td
><?=$message->created?></
td
><
td
><?=$message->isnew?></
td
>
</
tr
>
<?
php
endforeach?>
</
table
>
<
div
data-role
=
"footer"
>
<
div
data-role
=
"tabstrip"
>
<
a
href
=
"index"
data-icon
=
"/mobile_kendo/"
>Home</
a
>
<
a
href
=
""
data-icon
=
"refresh"
>Refresh</
a
>
<
a
href
=
"settings"
data-icon
=
"settings"
>Settings</
a
>
</
div
>
</
div
>
<
script
>
var app = new kendo.mobile.Application($(document.body), {
icon: "URL to a web clip icon"
});
</
script
>
I have a view page as below:
<
div
data-role
=
"view"
data-title
=
"Control Panel"
>
<
div
data-role
=
"header"
>
<
a
data-role
=
"backbutton"
>Back</
a
>
</
div
>
<
h2
>Message</
h2
>
<
p
>Date: <?=$message->message->created?></
p
>
<
p
>From: <?=$message->message->customer_name?></
p
>
<
p
>Email: <
a
href="mailto:<?=$message->message->email?>" target="_blank"><?=$message->message->email?></
a
></
p
>
<
p
>Telephone: <?=$message->message->customer_telephone?></
p
>
<
p
>Location IP:<?=$message->message->ip?></
p
>
<
p
>Message: <?=$message->message->message?></
p
>
<
p
><
a
href="../markasread/<?=$message->message->id?>/0">Mark as unread</
a
> | <
a
href="../delete/<?=$message->message->id?>">Delete</
a
></
p
>
<
div
data-role
=
"footer"
>
<
div
data-role
=
"tabstrip"
>
<
a
href
=
"index"
data-icon
=
"/mobile_kendo/"
>Home</
a
>
<
a
href
=
""
data-icon
=
"refresh"
>Refresh</
a
>
<
a
href
=
"settings"
data-icon
=
"settings"
>Settings</
a
>
</
div
>
</
div
>
</
div
>
<
script
>
var app = new kendo.mobile.Application($(document.body), {
icon: "URL to a web clip icon"
});
</
script
>
My Issues are:
1) When I select th
e
Customer Messages
link on the index page (messages/listall), the # is added automatically to the URL and is causing issues. 2) On the listall page, I select a message in the list and this does not put the # in front of the URL. This takes me to the view page but does not have the styling of the application applied. Why is this?
3) When I select the back button its adds the #, this sometimes works and sometimes doesn't depending on what page Im on. How can I get it to work for all pages?
4) As the code from the different pages is being appended to the main index page, when I perform an action, this is executed multiple times and I only want it to perform the operation once.
Any help would be much appreciated.