Skip to main content
Answer

Identical code from existing HTML/WYSIWYG page widget creates a different result in new page widget

  • October 16, 2023
  • 8 replies
  • 138 views

I created a new page for my site and copied an HTML/WYSIWYG widget from an existing page. However, the new page widget, using the identical code copied from the existing page widget, looks different from the original. If anyone has any suggestions of how to troubleshoot, it would be much appreciated. Thanks!

Here’s the code:

<h4>Manager Dashboard</h4>
<p><a href="/manage/users">My Staff</a></p>
<p><a href="/course/manage">Course Enrollments</a></p>
<p><a href="/learn/admin/reports">Reports</a></p>

Here’s the existing page widget desktop view:

 

Here’s the new page widget desktop view:

 

Best answer by gstager

CSS and HTML go hand in hand.

If you simply copied HTML from one page to the next and got a different result - it would mean that there is some CSS governing the HTML appearance.

Since the HTML you shared does not contain any classes or IDs - I am leaning towards a page or widget specific styling of those tags.

As @Bfarkas stated - it will be found in the branding and look area but will use the ID of the page or widget.

8 replies

gstager
Hero III
Forum|alt.badge.img+8
  • Hero III
  • October 16, 2023

Do you have some CSS that is specific to the first page and therefore not applied to the second?


Bfarkas
Hero III
Forum|alt.badge.img+6
  • Hero III
  • October 17, 2023

Do you have some CSS that is specific to the first page and therefore not applied to the second?

It’s gotta be something like that right? You don’t get that first picture from just the HTML given.


lrnlab
Hero III
Forum|alt.badge.img+10
  • Hero III
  • October 17, 2023

tend to agree with @gstager ...recheck that you have identical code...for the 2nd image, it look like you <p> tags are working as expected while in the original, they are not. Perhaps youre better off using some table code to keep things in a single row?


Bfarkas
Hero III
Forum|alt.badge.img+6
  • Hero III
  • October 17, 2023

IDK, in that first picture, I imagine those are still links right? I bet there is custom CSS restyling the p or p>a tags on that page to make it a pseudo menu. Usually lists ar eused for that, but could see using p’s too. Would be curious if there was a surrounding wrapper element too that you maybe didn’t bring in?


lrnlab
Hero III
Forum|alt.badge.img+10
  • Hero III
  • October 17, 2023

@jonv definitely pull the code on both and compare side by side...there is something in the first image causing it to appear as a single row rather than what you see in the second image.


  • Author
  • Novice I
  • October 18, 2023

Thanks so much for all the replies! This is clearly demonstrating my lack of CSS knowledge and skills. Have enlisted some outside help. Cheers:)


Bfarkas
Hero III
Forum|alt.badge.img+6
  • Hero III
  • October 18, 2023

From the sounds of it, the CSS is probably not on that widget or page but in the central style area. 


gstager
Hero III
Forum|alt.badge.img+8
  • Hero III
  • Answer
  • October 18, 2023

CSS and HTML go hand in hand.

If you simply copied HTML from one page to the next and got a different result - it would mean that there is some CSS governing the HTML appearance.

Since the HTML you shared does not contain any classes or IDs - I am leaning towards a page or widget specific styling of those tags.

As @Bfarkas stated - it will be found in the branding and look area but will use the ID of the page or widget.