Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

 
 
Thread Tools Display Modes
Prev Previous Post in Thread   Next Post in Thread Next
Old Jul 30th, 2004, 5:27 PM   #1
kurifu
Expert Programmer
 
kurifu's Avatar
 
Join Date: Jul 2004
Location: Halifax, Nova Scotia (Canada)
Posts: 784
Rep Power: 5 kurifu is on a distinguished road
Send a message via ICQ to kurifu Send a message via MSN to kurifu
As it ends up, it would appear that preg_replace actually has a limit to the size of the regular expression... this as you may know causes a bit of a problem, since I am writing a preparser for HTML pages which reads a very simple 'tag set' from an HTML file and replaces it with appropriate data (effectively producing a templating system which is REALLY easy for designers to understand and work with--without the need of a programming crash course).

The only problem is that I have one template that requires a really large section of code between an opening and closing 'if' tag to be replaces with a somewhat large table of data... and every time I run it, I get the following error:

Warning: Compilation failed: regular expression too large at offset 0 in ..... (ommited for security)

I can not find any information on google or php.net about there being a limit to the pattern size. Rewriting the code to work directecly with C/C++ style character streams is being avoided here, since PHP was not really intended for that purpose.

I am opening this thread for suggestion on how to get around this problem, any help would be appreciated. Thanks...
__________________
Clifford Matthew Roche <geek@cliffordroche.com>
Web Hosting: http://www.crd-hosting.com
Consulting: http://www.crdev-consulting.com
kurifu is offline   Reply With Quote
 

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 4:52 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC