Radicore Forum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » RADICORE » How To » refreshing
refreshing [message #869] Tue, 12 June 2007 11:51 Go to next message
interop is currently offline  interop
Messages: 45
Registered: October 2006
Member
My multi2 screens with new (add2) and delete (del1) do not refresh after adding or deleting an entry. In order to see the changes I must click 'reset'.
do you know what could cause this?
version 1.24, php5, mysql5
Re: refreshing [message #870 is a reply to message #869] Tue, 12 June 2007 19:52 Go to previous messageGo to next message
AJM is currently offline  AJM
Messages: 2371
Registered: April 2006
Location: Surrey, UK
Senior Member
That is very strange. I have just tried a multi2 form (Maintain Menu Contents) using version 1.24 as well as the upcoming 1.25, and I cannot reproduce this problem at all. Are you sure that you have replaced all the older scripts in the INCLUDES folder?

Re: refreshing [message #871 is a reply to message #870] Wed, 13 June 2007 08:43 Go to previous messageGo to next message
interop is currently offline  interop
Messages: 45
Registered: October 2006
Member
diff -r shows all my files in the includes directory are up to date with 1.24. I did more testing and noticed that (Maintain Menu Contents) uses a popup to select new entries. My multi2's that use popups work also. This only happens when I'm not using a popup to select new entries.
Re: refreshing [message #872 is a reply to message #871] Wed, 13 June 2007 08:53 Go to previous messageGo to next message
AJM is currently offline  AJM
Messages: 2371
Registered: April 2006
Location: Surrey, UK
Senior Member
What are you using to add new entries?

Re: refreshing [message #873 is a reply to message #872] Wed, 13 June 2007 09:21 Go to previous messageGo to next message
interop is currently offline  interop
Messages: 45
Registered: October 2006
Member
add2 is used to create new entries. This is the default value for the "Child forms" when creating a multi2 script with "generate php scripts (b)"
Re: refreshing [message #874 is a reply to message #873] Wed, 13 June 2007 10:20 Go to previous messageGo to next message
AJM is currently offline  AJM
Messages: 2371
Registered: April 2006
Location: Surrey, UK
Senior Member
I cannot reproduce this fault. Whenever I leave a Multi2 form by pressing a navigation button that form will *always* refresh its data from the database when it regains control irrespective of what happens in the child form.

The only time that the form will not refresh itself is if a popup button is pressed in the data area. Note that although both navigation buttons and popup buttons activate another form, their purpose is different, and returning from a popup does not cause a refresh.


Re: refreshing [message #875 is a reply to message #874] Wed, 13 June 2007 10:46 Go to previous messageGo to next message
interop is currently offline  interop
Messages: 45
Registered: October 2006
Member
Ok, I'm stepping through with a debugger and can't see where the refresh will happen. Can you point me in the right direction?
Re: refreshing [message #876 is a reply to message #875] Wed, 13 June 2007 11:03 Go to previous messageGo to next message
interop is currently offline  interop
Messages: 45
Registered: October 2006
Member
After I return from the add2 screen I am stepping through the std.multi2.inc file I never get to the getData() function.
Here is some info while stepping through std.multi2.inc:

$_POST is empty
$_GET only contains session_name
$return_from is set properly
$return_action is 'OK'
$popup_object is null
$selection is null

does any of this help?
Re: refreshing [message #877 is a reply to message #876] Wed, 13 June 2007 11:18 Go to previous messageGo to next message
AJM is currently offline  AJM
Messages: 2371
Registered: April 2006
Location: Surrey, UK
Senior Member
Now I see the problem. At line 262 in 'std.multi2.inc' you should see the following code:
// only read INNER if OUTER is not empty
if (count($outer_data) > 0) {
    if (!empty($return_from) AND !empty($return_action)) {
        ....
    } else {
        ....

This should be changed to the following:
// only read INNER if OUTER is not empty
if (count($outer_data) > 0) {
    if (!empty($return_from) AND !empty($popup_object)) {
        ....
    } else {
        ....

This fix has already been incorporated into the next release.


Re: refreshing [message #878 is a reply to message #877] Wed, 13 June 2007 12:18 Go to previous messageGo to next message
interop is currently offline  interop
Messages: 45
Registered: October 2006
Member
Thank you
Re: refreshing [message #886 is a reply to message #877] Thu, 28 June 2007 10:07 Go to previous messageGo to next message
interop is currently offline  interop
Messages: 45
Registered: October 2006
Member
AJM wrote on Wed, 13 June 2007 11:18

Now I see the problem. At line 262 in 'std.multi2.inc' you should see the following code:
// only read INNER if OUTER is not empty
if (count($outer_data) > 0) {
    if (!empty($return_from) AND !empty($return_action)) {
        ....
    } else {
        ....

This should be changed to the following:
// only read INNER if OUTER is not empty
if (count($outer_data) > 0) {
    if (!empty($return_from) AND !empty($popup_object)) {
        ....
    } else {
        ....

This fix has already been incorporated into the next release.


You may have already got this but I just noticed the same problem with multi3 I made the same fix as above on line 299 in std.multi3.inc and it seems to be working fine.
Re: refreshing [message #887 is a reply to message #886] Thu, 28 June 2007 10:55 Go to previous message
AJM is currently offline  AJM
Messages: 2371
Registered: April 2006
Location: Surrey, UK
Senior Member
Thanks for spotting that. It will be fixed in the next release.

Previous Topic: mnu_task.pattern_id='SEARCH'
Next Topic: javascript not working
Goto Forum:
  


Current Time: Sat Nov 30 09:55:15 EST 2024

Total time taken to generate the page: 0.01312 seconds