RingHTML: High-Performance HTML5 Parser & DOM Manipulation Library

136 views
Skip to first unread message

Youssef Saeed

unread,
Dec 13, 2025, 1:54:27 PM12/13/25
to The Ring Programming Language
                                                          logo.png                                                          
Hello everyone,

I'm thrilled to share the release of RingHTML—a powerful new Ring library for parsing and manipulating HTML documents!

Powered by the blazing-fast Lexbor engine, RingHTML brings high-performance scraping and DOM manipulation to Ring. It allows you to navigate the DOM tree, extract data, and build HTML programmatically using a simple and intuitive API.

Key Features:
  • High-Performance: Built on top of Lexbor, making it one of the fastest HTML5 parsers available.
  • CSS Selectors: Full support for `#id`, `.class`, `tag`, `parent child`, and complex selectors.
  • DOM Manipulation: Create, modify, insert, and remove nodes programmatically.
  • Navigation: Easily traverse parents, children, siblings, and specific elements.
  • Unicode Support: Full support for international characters and multilingual content.
Use Cases:

RingHTML is designed to help you with a variety of tasks:
  • Web Scraping: Download web pages and easily extract data like prices, headlines, or links using CSS selectors.
  • Data Extraction: Parse complex HTML reports or logs to convert them into structured data (Lists/Objects).
  • HTML Generation: Programmatically build valid HTML reports or email templates without messy string concatenation.
  • Content Sanitization: Load user-submitted HTML and strip out unwanted tags or attributes before saving.
Code Example:

Parsing HTML and finding elements is straightforward:

load "html.ring"

# Parse an HTML string
doc = new HTML('
<div class="content">
<h1>Welcome to RingHTML!</h1>
<ul class="links">
<li><a href="/docs">Docs</a></li>
<li><a href="/examples">Examples</a></li>
</ul>
</div>
')

# Find elements using CSS selectors
title = doc.find("h1")[1]
? "Title: " + title.text()

# Extract all links
links = doc.find("ul.links a")
for link in links
? "Link: " + link.text() + " -> " + link.attr("href")
next


Installation

Install easily via RingPM:

ringpm install ring-html from ysdragon

Learn MoreContributions are welcome!

Have ideas or found a bug? Please open an issue or submit a pull request on GitHub.

Your feedback is greatly appreciated!

Hope you find RingHTML useful!

Best regards,
Youssef

Mansour Ayouni

unread,
Dec 13, 2025, 2:11:36 PM12/13/25
to Youssef Saeed, The Ring Programming Language
Hello Youssef,

Yet another wise and useful choice of extension, thank you!
I enjoyed reading the story of Alexander Borisvor creating Lexbor...

I strated a stzHtml file in the Softanza FILE module months ago but I kept it basic (only a few functions) because I knew a c-extension was needed. Now you offer me the chance to make all the ideas I have rapidly.

KEEP THE NICE JOB,
All the best,
Mansour

--

---
You received this message because you are subscribed to the Google Groups "The Ring Programming Language" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ring-lang+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/ring-lang/f48a4d69-b802-4aba-81d2-916a9d02137an%40googlegroups.com.

Youssef Saeed

unread,
Dec 13, 2025, 2:36:08 PM12/13/25
to The Ring Programming Language
Hello Mansour,

Thank you so much for your kind words and encouragement!

I actually developed the core of this library months ago for my own web scraping needs. Thinking it might be useful to others as well, I decided to polish and release it. I am really glad to see it fits your needs!

It is great to hear that it fits perfectly with your plans for Softanza. It sounds like perfect timing since you were looking for a C-extension solution.

I can't wait to see what you build with it. Please let me know if you have any feedback once you start using it.

Best regards,
Youssef

Mahmoud Fayed

unread,
Dec 13, 2025, 11:01:11 PM12/13/25
to The Ring Programming Language
Hello Youssef

Thank you very much for developing this wonderful package 

Added to Ring Website - News Section

ringnews.png

Greetings,
Mahmoud

Youssef Saeed

unread,
Dec 14, 2025, 5:11:44 AM12/14/25
to The Ring Programming Language
Hello Mahmoud,

Thank you for your kind words and for adding it to the News Section.

Best regards,
Youssef

Mahmoud Fayed

unread,
Dec 14, 2025, 5:20:47 AM12/14/25
to The Ring Programming Language
Hello Youssef

You are welcome :D

Greetings,
Mahmoud

Bert Mariani

unread,
Dec 14, 2025, 8:28:57 AM12/14/25
to The Ring Programming Language
Hello Youssef

Thanks for the HTML library !!
This should make life a Lot Easier !

In the past I would download the Raw Html code from a Site.
Scan for the portions I was interested in.
Then spend some time extracting the data of interest.
It was tedious writing  the code.

Best Regards
Bert Mariani

Youssef Saeed

unread,
Dec 14, 2025, 3:55:38 PM12/14/25
to The Ring Programming Language
Hello Bert,

Thank you for your kind words!

I'm really glad the library helps solve that problem for you. It's definitely better than scanning through raw code manually!

Best regards,
Youssef

Azzeddine Remmal

unread,
Dec 14, 2025, 4:11:57 PM12/14/25
to The Ring Programming Language
Hello Youssef 

Thank you for the wonderful extension and all your valuable contributions.

 Regards, Azzeddine

Youssef Saeed

unread,
Dec 15, 2025, 1:21:57 AM12/15/25
to The Ring Programming Language
Hello Azzeddine,

Thank you for your kind words!

Best regards,
Youssef

Bert Mariani

unread,
Apr 7, 2026, 3:39:31 PMApr 7
to The Ring Programming Language
Hello Youssef et ALL

Using your "html.ring" library 
What a breeze !!
Extracting financial data from a web site.

Attached 
     HTML-Get-Financials.ring   // New HTML program
     Curl-Get-FIN.ring                    // Old  html program scrapper

=================
This site stopped working for me when they changed some HTML formats around

With your --  load "html.ring"  --   library        // <<<=== ring-html CSS selector parser
I was able to re-write it and get the financial  data I wanted for stocks 
It made life So Much Easier !!
Thanks Youssef !!

==================
With the DEBUG = 0   Flag off, 
      From my following directory, It uses input tickers list and outputs to CSV files 
      "C:\NetData\INDEX\Financial.ini"
      "C:\NetData\INDEX\Financial.result"

DEMO
With the DEBUG = 1  Flag on ( which is ON in the attached program for demo )
        Using --  aSymbols = ["APPL","MSFT","NVDA","TSLA","NFLX","META","GOOGL","AGX","VRT"]
        It writes the following output to the screen ... example


========================================
DEBUG: Financial Parts Fetched -- MSFT
========================================
  [ 0] Market Cap ($M)           : 2768.87
  [ 1] Most Recent Earnings      : 4.14
  [ 2] Next Earnings Date        : 04/29/26
  [ 3] Earnings Per Share ttm    : 15.38
  [ 4] EPS Growth vs. Prev Qtr  : 0.24%
  [ 5] EPS Growth vs. Prev Year  : 28.17%
  [ 6] Annual Dividend Rate, $   : 0
  [ 7] Annual Dividend Yield     : 0
  [ 8] Most Recent Dividend      : 0.910
  [ 9] Next Ex-Dividends Date    : 05/21/26
  [10] Dividend Payable Date     : 06/11/26
  [11] Dividend Payout Ratio     : 22.01%
========================================
  --- RAW labels from page (56 rows) ---
      LABEL: [Market Capitalization, $K]  VAL: [2,768,868,480]
      LABEL: [Enterprise Value, $K]  VAL: [2,897,958,400]
      LABEL: [Shares Outstanding, K]  VAL: [7,425,629]
      LABEL: [Float, K]  VAL: [7,423,401]
      LABEL: [% Float]  VAL: [99.97%]
      LABEL: [Short Interest, K]  VAL: [79,836]
      LABEL: [Short Float]  VAL: [1.08%]
      LABEL: [Days to Cover]  VAL: [2.51]
      LABEL: [Short Volume Ratio]  VAL: [0.29]
      LABEL: [% of Insider Shareholders]  VAL: [0.03%]
      LABEL: [% of Institutional Shareholders]  VAL: [71.13%]
      LABEL: [Annual Sales, $]  VAL: [281,724 M]
      LABEL: [Annual Net Income, $]  VAL: [101,832 M]
      LABEL: [Last Quarter Sales, $]  VAL: [81,273 M]
      LABEL: [Last Quarter Net Income, $]  VAL: [38,458 M]
      LABEL: [EBIT, $]  VAL: [142,559 M]
      LABEL: [EBITDA, $]  VAL: [176,712 M]
      LABEL: [1-Year Return]  VAL: [3.42%]
      LABEL: [3-Year Return]  VAL: [30.31%]
      LABEL: [5-Year Return]  VAL: [43.01%]
      LABEL: [5-Year Revenue Growth]  VAL: [96.99%]
      LABEL: [5-Year Earnings Growth]  VAL: [136.81%]
      LABEL: [5-Year Dividend Growth]  VAL: [62.81%]
      LABEL: [Most Recent Earnings]  VAL: [4.14 on 01/28/26]
      LABEL: [Next Earnings Date]  VAL: [04/29/26 [--]]
      LABEL: [Earnings Per Share ttm]  VAL: [15.38]
      LABEL: [EPS Growth vs. Prev Qtr]  VAL: [0.24%]
      LABEL: [EPS Growth vs. Prev Year]  VAL: [28.17%]
      LABEL: [Annual Dividend & Yield (Paid)]  VAL: [3.48 (0.93%)]
      LABEL: [Annual Dividend & Yield (Fwd)]  VAL: [3.64 (0.97%)]
      LABEL: [Most Recent Dividend]  VAL: [0.910 on 02/19/26]
      LABEL: [Next Ex-Dividends Date]  VAL: [05/21/26]
      LABEL: [Dividend Payable Date]  VAL: [06/11/26]
      LABEL: [Dividend Payout Ratio]  VAL: [22.01%]
      LABEL: [Most Recent Split]  VAL: [2-1 on 02/18/03]
      LABEL: [Price/Earnings ttm]  VAL: [24.28]
      LABEL: [Price/Earnings forward]  VAL: [22.69]
      LABEL: [Price/Earnings to Growth]  VAL: [1.42]
      LABEL: [Return-on-Equity %]  VAL: [32.34%]
      LABEL: [Return-on-Assets %]  VAL: [18.49%]
      LABEL: [Profit Margin %]  VAL: [36.15%]
      LABEL: [Debt/Equity]  VAL: [0.10]
      LABEL: [Price/Sales]  VAL: [9.84]
      LABEL: [Price/Cash Flow]  VAL: [20.41]
      LABEL: [Price/Book]  VAL: [7.09]
      LABEL: [Book Value/Share]  VAL: [52.64]
      LABEL: [Interest Coverage]  VAL: [4.76]
      LABEL: [60-Month Beta]  VAL: [1.11]
      LABEL: [02/19/26]  VAL: [$0.9100]
      LABEL: [11/20/25]  VAL: [$0.9100]
      LABEL: [08/21/25]  VAL: [$0.8300]
      LABEL: [05/15/25]  VAL: [$0.8300]
      LABEL: [02/20/25]  VAL: [$0.8300]
      LABEL: [11/21/24]  VAL: [$0.8300]
      LABEL: [08/15/24]  VAL: [$0.7500]
      LABEL: [05/15/24]  VAL: [$0.7500]
========================================
========================================
DEBUG: Financial Parts Fetched -- VRT
========================================
  [ 0] Market Cap ($M)           : 98.99
  [ 1] Most Recent Earnings      : 1.36
  [ 2] Next Earnings Date        : 04/22/26
  [ 3] Earnings Per Share ttm    : 4.19
  [ 4] EPS Growth vs. Prev Qtr  : 9.68%
  [ 5] EPS Growth vs. Prev Year  : 37.37%
  [ 6] Annual Dividend Rate, $   : 0
  [ 7] Annual Dividend Yield     : 0
  [ 8] Most Recent Dividend      : 0.063
  [ 9] Next Ex-Dividends Date    : 03/17/26
  [10] Dividend Payable Date     : 03/26/26
  [11] Dividend Payout Ratio     : 3.20%
========================================
  --- RAW labels from page (54 rows) ---
      LABEL: [Market Capitalization, $K]  VAL: [98,989,584]
      LABEL: [Enterprise Value, $K]  VAL: [100,174,184]
      LABEL: [Shares Outstanding, K]  VAL: [382,598]
      LABEL: [Float, K]  VAL: [363,430]
      LABEL: [% Float]  VAL: [94.99%]
      LABEL: [Short Interest, K]  VAL: [8,912]
      LABEL: [Short Float]  VAL: [2.33%]
      LABEL: [Days to Cover]  VAL: [1.06]
      LABEL: [Short Volume Ratio]  VAL: [0.67]
      LABEL: [% of Insider Shareholders]  VAL: [5.01%]
      LABEL: [% of Institutional Shareholders]  VAL: [89.92%]
      LABEL: [Annual Sales, $]  VAL: [10,230 M]
      LABEL: [Annual Net Income, $]  VAL: [1,333 M]
      LABEL: [Last Quarter Sales, $]  VAL: [2,880 M]
      LABEL: [Last Quarter Net Income, $]  VAL: [445,600 K]
      LABEL: [EBIT, $]  VAL: [2,030 M]
      LABEL: [EBITDA, $]  VAL: [2,345 M]
      LABEL: [1-Year Return]  VAL: [301.55%]
      LABEL: [3-Year Return]  VAL: [1,981.50%]
      LABEL: [5-Year Return]  VAL: [1,051.45%]
      LABEL: [5-Year Revenue Growth]  VAL: [134.06%]
      LABEL: [5-Year Earnings Growth]  VAL: [438.46%]
      LABEL: [5-Year Dividend Growth]  VAL: [1,300.00%]
      LABEL: [Most Recent Earnings]  VAL: [1.36 on 02/11/26]
      LABEL: [Next Earnings Date]  VAL: [04/22/26 [--]]
      LABEL: [Earnings Per Share ttm]  VAL: [4.19]
      LABEL: [EPS Growth vs. Prev Qtr]  VAL: [9.68%]
      LABEL: [EPS Growth vs. Prev Year]  VAL: [37.37%]
      LABEL: [Annual Dividend & Yield (Paid)]  VAL: [0.16 (0.06%)]
      LABEL: [Annual Dividend & Yield (Fwd)]  VAL: [0.25 (0.10%)]
      LABEL: [Most Recent Dividend]  VAL: [0.063 on 03/17/26]
      LABEL: [Next Ex-Dividends Date]  VAL: [03/17/26]
      LABEL: [Dividend Payable Date]  VAL: [03/26/26]
      LABEL: [Dividend Payout Ratio]  VAL: [3.20%]
      LABEL: [Price/Earnings ttm]  VAL: [62.36]
      LABEL: [Price/Earnings forward]  VAL: [42.44]
      LABEL: [Price/Earnings to Growth]  VAL: [1.32]
      LABEL: [Return-on-Equity %]  VAL: [49.55%]
      LABEL: [Return-on-Assets %]  VAL: [15.30%]
      LABEL: [Profit Margin %]  VAL: [13.03%]
      LABEL: [Debt/Equity]  VAL: [0.74]
      LABEL: [Price/Sales]  VAL: [9.77]
      LABEL: [Price/Cash Flow]  VAL: [51.14]
      LABEL: [Price/Book]  VAL: [25.36]
      LABEL: [Book Value/Share]  VAL: [10.30]
      LABEL: [Interest Coverage]  VAL: [21.23]
      LABEL: [60-Month Beta]  VAL: [2.04]
      LABEL: [03/17/26]  VAL: [$0.0630]
      LABEL: [11/25/25]  VAL: [$0.0630]
      LABEL: [06/16/25]  VAL: [$0.0380]
      LABEL: [03/18/25]  VAL: [$0.0380]
      LABEL: [12/03/24]  VAL: [$0.0380]
      LABEL: [09/17/24]  VAL: [$0.0250]
      LABEL: [06/17/24]  VAL: [$0.0250]
========================================


Best Regards
Bert Mariani

Curl-Get-FIN.ring
HTML-Get-Financials.ring

Youssef Saeed

unread,
Apr 7, 2026, 4:17:24 PMApr 7
to The Ring Programming Language
Hello Bert,

Wow, this is fantastic! Thank you so much for sharing. It's awesome to see RingHTML being used for a real-world project like this. I'm thrilled it made your life so much easier.

Best regards,
Youssef
Reply all
Reply to author
Forward
0 new messages