Jump to content

Recommended Posts

Posted

I'm using TuniHTMLMemo, switching to source code editing mode, and pasting the HTML I've written into it.

There is a table inside the HTML, and I create the list items myself. However, it automatically changes the placement of the list items, which disrupts my design.


It also removes the first three lines of HTML tags.
<!DOCTYPE html>
<html>
<head>

Posted

Hello,

Yes, I think adding a non-breaking space (&nbsp;) inside <tbody> might prevent it from being removed.
Can you try this and see if {urun_listesi} stays in place after editing?

<tbody>
  {urun_listesi} &nbsp;
</tbody>

 

Posted
32 minutes ago, Yakup ULUTAŞ said:

image.png.b5f53ea5f317cf213a6f441792d98db1.png

If this doesn't work, another option could be adding an empty <tr> with a non-breaking space:

<tbody>
  {urun_listesi}
  <tr><td>&nbsp;</td></tr>
</tbody>

or

<tbody>
  {urun_listesi}
  <tr style="display: none;"><td></td></tr>
</tbody>

 

Posted
16 minutes ago, Yakup ULUTAŞ said:

siparis_taslak__.html 6.09 kB · 0 downloads

Yes, it turns out your code didn't meet the HTML specification.
You can verify this behavior in any browser. This is not a bug in UniHTMLMemo.

Try to wrap {urun_listesi} inside <tr> and <td> tags, like this:

<tbody>
  <tr>
    <td colspan="5">{urun_listesi}</td>
  </tr>
</tbody>

Or, if {urun_listesi} consists of multiple table rows (<tr>), you could do:

<tbody>
  {urun_listesi}
  <tr style="display:none;"><td colspan="5">&nbsp;</td></tr>
</tbody>

 

Posted
2 hours ago, Yakup ULUTAŞ said:

But you're adding an extra empty line. Is this really the solution?

<tbody>
  {urun_listesi}
  <tr style="display:none;">
    <td colspan="5">&nbsp;</td>
  </tr>
</tbody>

?

Posted
2 hours ago, Yakup ULUTAŞ said:

And how will we fix the removed head tag?

If your goal is to display or use a complete HTML document including tags like <!DOCTYPE html>, <html>, <head>, then TUniHTMLFrame is the right component.

TUniHTMLMemo is designed only for editing HTML fragments (body content) and removes those tags automatically.

Try using TUniHTMLFrame instead, as it's meant to handle full HTML pages.

Posted
2 minutes ago, Sherzod said:

Eğer amacınız <!DOCTYPE html>, <html>, <head> gibi etiketleri içeren tam bir HTML belgesini görüntülemek veya kullanmaksa, TUniHTMLFrame doğru bileşendir.

TUniHTMLMemo yalnızca HTML parçalarını (gövde içeriğini) düzenlemek için tasarlanmıştır ve bu etiketleri otomatik olarak kaldırır.

Bunun yerine, tam HTML sayfalarını işlemek için tasarlanmış olan TUniHTMLFrame'i kullanmayı deneyin.

But the user needs to be able to modify the HTML design as they wish and save it. Does the component you mentioned support this?

Posted
6 minutes ago, Yakup ULUTAŞ said:

But the user needs to be able to modify the HTML design as they wish and save it. Does the component you mentioned support this?

If the user needs to edit and save an entire HTML document, TUniHTMLMemo might work, but it does not support <!DOCTYPE>, <html>, or <head> elements.

A possible workaround is to store only the <body> content in TUniHTMLMemo and programmatically add the missing document structure when saving or displaying the content.

Alternatively, if rich text (WYSIWYG) editing is required, integrating a JavaScript-based editor like TinyMCE or CKEditor inside TUniHTMLFrame could be a better solution.

Posted
1 hour ago, Sherzod said:

If the user needs to edit and save an entire HTML document, TUniHTMLMemo might work, but it does not support <!DOCTYPE>, <html>, or <head> elements.

A possible workaround is to store only the <body> content in TUniHTMLMemo and programmatically add the missing document structure when saving or displaying the content.

Alternatively, if rich text (WYSIWYG) editing is required, integrating a JavaScript-based editor like TinyMCE or CKEditor inside TUniHTMLFrame could be a better solution.

How can I use these? Is there a guide or forum available?  TinyMCE looks nice.

Posted
13 minutes ago, Yakup ULUTAŞ said:

How can I use these? Is there a guide or forum available?  TinyMCE looks nice.

There are example solutions for using TinyMCE on the forum.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...