(oops, what a bad subject!!!)
we have some variable type in plugins, like select, boolean and ...
your program change them with some HTML codes.
NOW, i want to change some property of that html tags.
for example:
the default tag for string is: <input type=text name=fieldname>
i want to ADD a new property to it...
like: <input type=text name=fieldname property=value>
note that i want to add that to ONLY THIS plugin :>
best regards, omid
property for variables!!
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: property for variables!!
Hm. Why do you need this?
Anyways, you can emit ANY input tag, or stuff using the 'content' type (there where you enter 'boolean' or 'select' usually. The contents of what you put into the 'default' property will emitted there.
So use this:
Regards,
Garvin
Anyways, you can emit ANY input tag, or stuff using the 'content' type (there where you enter 'boolean' or 'select' usually. The contents of what you put into the 'default' property will emitted there.
So use this:
Code: Select all
$propbag->add('type', 'content');
$propbag->add('default', '<input type="serendipity[plugin][yourinputfielname]" value="value" property="property" />');
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Can't you specify that direction via a CSS variable/attribute?
Regards,
Garvin
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
You could just style:
or something like that? We could create a new constant 'direction' for each language, which we could use in admin/style.css as:
direct: {DIRECTION}
so we could implement that into our default stylesheet without you having to create a new template set if someone wants to use RTL languages.
Was that what you meant?
Regards,
Garvin
Code: Select all
input {
direction: rtl;
}
direct: {DIRECTION}
so we could implement that into our default stylesheet without you having to create a new template set if someone wants to use RTL languages.
Was that what you meant?
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
niceWe could create a new constant 'direction' for each language
not exactlyWas that what you meant?
we have a lot of text field in the stage....
some of them like Title should be RTL
but some of them like HomepageURL should be LTR!!
i want to change ONLY one of my text fields to LTR
got it??
if you want i can upload a sample for you
regards, omid
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Hi oxygenws!
* templates/default/admin/style.css will set 'direction: {LANG_DIRECTION}' to the Body Element.
* Added CSS classes 'direction_ltr' and 'direction_rtl' for assigning to special elements
* Added 'lang_direction' plugin bag value to contain the direction for the configuration of a plugin element.
So you can now define LANG_CHARSET in your language file, and use this for plugins:
The default direction if not set is always the direction of the Language file.
It should be contained in the snapshot which will be created later today.
Regards,
Garvin
Okay. I just committed to CVS:we have a lot of text field in the stage....
some of them like Title should be RTL
but some of them like HomepageURL should be LTR!!
i want to change ONLY one of my text fields to LTR
* templates/default/admin/style.css will set 'direction: {LANG_DIRECTION}' to the Body Element.
* Added CSS classes 'direction_ltr' and 'direction_rtl' for assigning to special elements
* Added 'lang_direction' plugin bag value to contain the direction for the configuration of a plugin element.
So you can now define LANG_CHARSET in your language file, and use this for plugins:
Code: Select all
$propbag->add('type', 'boolean');
$propbag->add('name', PLUGIN_EVENT_SPAMBLOCK_BODYCLONE);
$propbag->add('description', PLUGIN_EVENT_SPAMBLOCK_BODYCLONE_DESC);
$propbag->add('default', true);
$propbag->add('lang_direction', 'ltr');
It should be contained in the snapshot which will be created later today.
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/