vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Problem when "update" options (https://vborg.vbsupport.ru/showthread.php?t=222157)

cionfs 08-31-2009 05:07 PM

Problem when "update" options
 
Hi @ all. :)

I've a problem with the "memory" of dropdown men? on my product.

When I change a setting and save everything back as before. But the change takes effect


Example.

I go to my options

https://vborg.vbsupport.ru/

I set right and click to Save

http://img43.imageshack.us/img43/921/dfdddddddddddd.jpg

http://img35.imageshack.us/img35/963...ddddddddd2.jpg

After Save... return "left"

https://vborg.vbsupport.ru/

How can I solve it?

Thank you. :)

Lynne 08-31-2009 05:12 PM

This is a modification you are coding yourself?

cionfs 08-31-2009 05:24 PM

Yes, is a new option on mytranslator.

Everything works, in the new release, but not the dropdown men?.

Lynne 08-31-2009 05:35 PM

What are all the settings that are in the export for the product? Perhaps you have something wrong in there.

cionfs 08-31-2009 06:05 PM

This is the code of men?

Code:

<setting varname="mytranslator_position" displayorder="5">
  <datatype>free</datatype> 
  <optioncode>select:piped
    left|Left
    right|Right
    center|Center
  </optioncode>
  <defaultvalue>center</defaultvalue>
</setting>

Is wrong?

Lynne 08-31-2009 06:51 PM

It looks correct to me. Have you tried closing your browser and then opening it again and seeing if the problem goes away? Or clearing the cache? Have you checked the database to see if anything is changing? Have you checked your error logs to see if something is in there?

cionfs 08-31-2009 07:56 PM

Quote:

Originally Posted by Lynne (Post 1877319)
Have you tried closing your browser and then opening it again and seeing if the problem goes away?

Yes.

Quote:

Originally Posted by Lynne (Post 1877319)
Or clearing the cache?

Yes.

Quote:

Originally Posted by Lynne (Post 1877319)
Have you checked the database to see if anything is changing?

No change.

Quote:

Originally Posted by Lynne (Post 1877319)
Have you checked your error logs to see if something is in there?

No error logs.

If I try to change select:piped to radio:piped nothing is selected... all values are blank.

Lynne 08-31-2009 08:52 PM

Have you tried deleting the option and creating it again? When you say no error logs, do you mean nothing is in them, or you have no error logs?

cionfs 08-31-2009 09:05 PM

Quote:

Originally Posted by Lynne (Post 1877387)
Have you tried deleting the option and creating it again?

Yes.

Quote:

Originally Posted by Lynne (Post 1877387)
When you say no error logs, do you mean nothing is in them, or you have no error logs?

Nothing in error logs. :)

Lynne 08-31-2009 10:30 PM

Hmmmm..... um...... OK..... have you tried turning off all other modifications - turn off both products and extra plugins - so that only this one product is 'on'? I'm kinda running out of suggestions here. I can't think of why that wouldn't work if there is no error at all. Conflict of id? I don't think vbulletin would let that happen though...

cionfs 09-01-2009 07:27 AM

Quote:

Originally Posted by Lynne (Post 1877443)
have you tried turning off all other modifications - turn off both products and extra plugins - so that only this one product is 'on'?


Yes but doesn't work.

Thank you. :)

Marco van Herwaarden 09-01-2009 08:10 AM

Why have you choosen for free text instead of a single selection menu?

cionfs 09-01-2009 09:32 AM

Quote:

Originally Posted by Marco van Herwaarden (Post 1877640)
Why have you choosen for free text instead of a single selection menu?

Why? If I use selection men? I don't have to insert datatype?

Quote:

<datatype>free</datatype>
What datatype should I enter?

@All: Thank you for your support :up:

Marco van Herwaarden 09-01-2009 09:34 AM

Don't go editing the XML, just create a new profile field and select single selection menu as type.

cionfs 09-01-2009 09:48 AM

Nothing. If I create this field

Code:

  <setting varname="mytranslator_position2" displayorder="5">
    <optioncode>select:piped
      left|Left
      right|Right
      center|Center
    </optioncode>
    <defaultvalue>center</defaultvalue>
  </setting>

Doesn't work. Uhm....

Marco van Herwaarden 09-01-2009 10:09 AM

Sorry my previous reply was about Profile Fields, not vB Options.

I just tested it with the following and had no problems:

Option code:
Code:

select:piped
left|Left
right|Right
center|Center

Default: center

All other fields left at default (exept title and description etc..).

cionfs 09-01-2009 10:21 AM

For everything else works. Only this is just wrong.

Could be a template's cache issue?

Marco van Herwaarden 09-01-2009 10:30 AM

Doubt that. If anything then i suspect a modification is causing this.

cionfs 09-01-2009 11:02 AM

I try to use this code

Code:

  <setting varname="myt_position" displayorder="14">
    <datatype>free</datatype>
    <optioncode>select:piped
      0|Left
      1|Right
      2|Center</optioncode>
    <defaultvalue>2</defaultvalue>
  </setting>

and It works. But... why this code works and the old code doesn't work?

What are the difference between

Code:

left|Left
right|Right
center|Center

and

Code:

0|Left
1|Right
2|Center


Perhaps select: piped functions only if the first value is numeric and the second is an attribute?

Uhm.... This is a mystery ... :confused:

Marco van Herwaarden 09-01-2009 11:31 AM

Both should work.

cionfs 09-01-2009 11:48 AM

The first code doesn't work. The second code works.

Question... if I use MyTranslator_position_set for settinggroup and mytranslator_position for a simple setting, this could be creating problems?

Marco van Herwaarden 09-01-2009 11:51 AM

What vB version are you using?

cionfs 09-01-2009 12:00 PM

Version 3.8.4

Marco van Herwaarden 09-01-2009 12:36 PM

Are you creating this option using the normal Admin interface or are you editing and uploading a XML-file?

cionfs 09-01-2009 12:42 PM

Only with the XML file. :)

Marco van Herwaarden 09-02-2009 10:40 AM

Then you should stop editing XML-files. This is not a supported option and can lead to issues like this. Why not just use the normal AdminCP interface?

cionfs 09-03-2009 09:48 AM

Changing an XML file with an XML editor is more convenient for me.
I will try at this point directly from the admin panel. :)

Marco van Herwaarden 09-03-2009 11:10 AM

You find it more convenient to scratch your head asking yourself why someone doesn't work, where you could also use the tools provided and it will work on the first try.

cionfs 09-03-2009 12:35 PM

I solved the problem.

This code was wrong:

Code:

  <setting varname="mytranslator_position2" displayorder="5">
    <optioncode>select:piped
      left|Left
      right|Right
      center|Center
    </optioncode>
    <defaultvalue>center</defaultvalue>
  </setting>

This is correct

Code:

<setting varname="mytranslator_position" displayorder="5">
  <datatype>free</datatype> 
  <optioncode><![CDATA[radio:piped
left|Left
right|Right
center|Center
]]>
  </optioncode>
  <defaultvalue>left</defaultvalue>
</setting>

and It works fine! :)

Thank you for your support. :)

Lynne 09-03-2009 02:55 PM

Glad you got it working, cionfs, and thanks for posting what worked since it may help someone else in the future.


All times are GMT. The time now is 08:09 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01311 seconds
  • Memory Usage 1,782KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (8)bbcode_code_printable
  • (9)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (30)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete