App MobilePut your business on a mobile app. No Coding, no fuss. Try it now !
Forum openElement Homepage
Forum Home Forum Home >

openElement

> Element Editor
  New Posts New Posts RSS Feed - Help dynamically accessing properties in html
  FAQ FAQ  Forum Search   Register Register  Login Login

Help dynamically accessing properties in html

 Post Reply Post Reply
Author
Message
Samyoue View Drop Down
Newbie
Newbie


Joined: 25 Feb 2017
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Samyoue Quote  Post ReplyReply Direct Link To This Post Topic: Help dynamically accessing properties in html
    Posted: 25 Feb 2017 at 23:47
Hi I'm creating an element which is populated by an object property defined in the editor, got everything just about working I think except whenever I access a property within a loop it seems to add a newline after it

Eg. The property value is
1234

But what is written into the html is this
1234
.
(without the ".")

As its mid HTML tag its causing errors...
I'll try to get an actual code snippet posted later (away from pc atm) but any ideas?

Thanks for any help,

Sam
Back to Top
Dmit OE View Drop Down
Admin Group
Admin Group
Avatar

Joined: 31 Mai 2012
Status: Offline
Points: 4315
Post Options Post Options   Thanks (0) Thanks(0)   Quote Dmit OE Quote  Post ReplyReply Direct Link To This Post Posted: 26 Feb 2017 at 01:42
Hi,

I'ts a bug fixed in the latest beta version which you can alreayd use - with caution, I am fixing newly detected bugs at the moment, but for most project it seems operational.

http://forum.openelement.com/en/forum_posts.asp?TID=996&PID=4734&title=english#4734

Make sure to back up your projects and elements.

Do you plan to share your element?
Back to Top
Samyoue View Drop Down
Newbie
Newbie


Joined: 25 Feb 2017
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Samyoue Quote  Post ReplyReply Direct Link To This Post Posted: 01 Mar 2017 at 03:18
Thanks, that solved it... also seems to be a bug in dynamically generated tables having border spacing preset and I can't seem to override it...

Yes I'm planning on sharing it when its finished - its going to be a Tab element
on a side note, I'm struggling with containers - I'm after Accordion style generated containers but can't seem to get it working... any help on this would be greatly appreciated

Sam
Back to Top
Dmit OE View Drop Down
Admin Group
Admin Group
Avatar

Joined: 31 Mai 2012
Status: Offline
Points: 4315
Post Options Post Options   Thanks (0) Thanks(0)   Quote Dmit OE Quote  Post ReplyReply Direct Link To This Post Posted: 01 Mar 2017 at 08:59
Could you please provide more details on the border spacing issue? I don't see at all what you mean.

Working with containers in OE may get difficult. I am not sure that Element Editor allows more than one container per element, though normally it should. What you can try in any case, is to ask user to put Groups of Elements inside your element, a little like in my RespPanel element (you can find it in SensBlack and SensWhite templates and look how it is made). Like this, users will be able to use their existing Groups, and choose for EACH Group whether its elements are positioned "absolute" or "relative". then you can use CSS and JS scripts to control the display of these Groups.


Back to Top
Samyoue View Drop Down
Newbie
Newbie


Joined: 25 Feb 2017
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote Samyoue Quote  Post ReplyReply Direct Link To This Post Posted: 01 Mar 2017 at 22:50
<table style=" border-spacing:0 px; background-color:cyan">
 <tr>
 <td>test</td>
 <td>number 2</td>
 <td>this is 3</td>
</tr>
</table>
creates the issue but adding a class to the row seems to fix it:
<table style=" border-spacing:0 px; background-color:cyan">
 <tr class="tabTop">
 <td>test</td>
 <td>number 2</td>
 <td>this is 3</td>
</tr>
</table>

I'll look into the groups idea and your reps panel later, cheers,

Sam
Back to Top
Dmit OE View Drop Down
Admin Group
Admin Group
Avatar

Joined: 31 Mai 2012
Status: Offline
Points: 4315
Post Options Post Options   Thanks (0) Thanks(0)   Quote Dmit OE Quote  Post ReplyReply Direct Link To This Post Posted: 02 Mar 2017 at 09:35
You have space before px; try this:

<table cellspacing="10" style="border-spacing:0; ....>

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 10.11
Copyright ©2001-2012 Web Wiz Ltd.

This page was generated in 0,031 seconds.