Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 1,000 results for
preg_replace
- Page 1
'30% of Activities Performed by Humans Could Be Automated with AI'
Community Center
2 Days Ago
by Johannes C.
**Alexander De Ridder, AI visionary and CTO of SmythOS, discusses the transformative power of specialized AI systems and the future of human-AI collaboration.** ![header-agi-talks-adr.jpg](https://static.daniweb.com/attachments/4/cf1ab716c18354710010dabb4e9e2a9a.jpg) In the newest interview of our AGI Talks series, **Alexander De Ridder** …
Using Natural Language to Query SQL Databases with Python LangChain Module
Programming
Computer Science
1 Week Ago
by usmanmalik57
The advent of large language models (LLM) has replaced complex scripts with natural language for automating various tasks. You can now use LLM to interact with your databases using natural language, which makes life easier for people who do not have sufficient SQL knowledge. In this article, you will learn how to retrieve information from SQL …
Re: ASUS Laptops - my experience
Hardware and Software
2 Weeks Ago
by toneewa
I wouldn't worry about not having any ASUS utilities. You can always download them later, [here](https://www.asus.com/support/download-center/). I consider them all bloatware. Having the partition as an MBR and then installing a Windows image as GPT, is like going to replace your spare tire and finding out it has a different lug nut bolt pattern…
Converting PDF Image to CSV Using Multimodal Google Gemini Pro
Programming
Computer Science
2 Months Ago
by usmanmalik57
In this article, you will learn to use [Google Gemini Pro](https://blog.google/technology/ai/google-gemini-ai/), a state-of-the-art multimodal generative model, to extract information from PDF and convert it to CSV files. You will use a simple text prompt to tell Google Gemini Pro about the information you want to extract. This is a valuable skill …
PDF Image Table Extractor Web App with Google Gemini Pro and Streamlit
Programming
Computer Science
2 Months Ago
by usmanmalik57
In my previous article, I explained [how to convert PDF image to CSV using Multimodal Google Gemini Pro](https://www.daniweb.com/programming/computer-science/tutorials/541365/converting-pdf-image-to-csv-using-multimodal-google-gemini-pro). To do so, I wrote a Python script that passes text command to [Google Gemino Pro](https://blog.google/…
C++ programming error
Programming
2 Months Ago
by sammieb
I am trying to enter a single string in C++ in which I give a URL citation. the entire line is as follows: cout << 'furey, edward "sphere calculator" at https://www.calculatorsoup.com/calculators/geometry-solids/sphere.php from calculatorsoup, https://www.calculatorsoup.com - online calculators' << endl; I am getting the…
Re: Is Coding About Authoring or Achieving a Specification?
Programming
2 Months Ago
by rproffitt
What standards are you asking about? What happens when your standard doesn't fit your use case? (spoiler) ![image_2024-01-27_115711909.png](https://static.daniweb.com/attachments/1/361846dbfc9dcb5adc5f4800c2a3933d.png) https://xkcd.com/927/ As I wrote more and more code I did gravitate toward standards. But with each job, there was yet …
Re: ASUS Laptops - my experience
Hardware and Software
1 Month Ago
by toneewa
Indeed, I recommend to anyone that has USB ports to use the magnetic plugs for mini and micro USB ports. I see you could have the Thunderbolt 4 USB-C, so I'm sure it did cost little more. That would check one of my boxes. 144hz+ would be another. I don't need bloodshot eyes from 60hz. If you are a DIY fixer, you can also [replace the TB4 ports](…
Re: C++ programming error
Programming
2 Months Ago
by rproffitt
You'll want to escape those quote marks and maybe more. Read https://en.cppreference.com/w/cpp/language/escape Example follows: #include <iostream> using namespace std; int main() { cout << "furey, edward \"sphere calculator\" at https://www.calculatorsoup.com/calculators/geometry-solids/…
Re: Postfix authentication problem
Hardware and Software
Linux and Unix
1 Month Ago
by chickenbirds
> I am trying to set-up Postfix on my Ubuntu local web development machine for send-only e-mails using Gmail so I can test e-mails sent by a web app I am developing. Even though this is an old post I wanted to reply as I found it while trying to setup my own postfix mailrelay on my private cloud server with Debian that hosts our small …
preg replace bugs
Programming
Web Development
15 Years Ago
by cwarn23
… are sending me crazy are as follows: [CODE=php]$textb=
preg_replace
("/([^)])( | | |\>| \>| \>| \>… was taken out from this spot. $textb=
preg_replace
("/(\'(.*)\')/is","<font color=#c…;'$2'</font>",$textb); $textb=
preg_replace
("/(\'([^'])\')/is","'</font>$2…
Problem in Preg Replace
Programming
Web Development
13 Years Ago
by jhbalaji
…='_blank'>".$textlinksname."</a>"; $body =
preg_replace
($suchmuster,$replace,$body,200);[/CODE] Since the variable $body contains…='_blank'>".$textlinksname."</a>"; $body =
preg_replace
($suchmuster,$replace,$body,200); // Here the Output will be // <…
preg_replace blues
Programming
Web Development
12 Years Ago
by diafol
… value', 'another_key' => 'spaghettiness', .... };[/CODE] What I need is some
preg_replace
stuff to replace the values in the template.php file…! I've been working along the lines of [CODE]$newcontent =
preg_replace
($regex,$newvalue,$tmpfilecontents);[/CODE] Unfortunately, it's the regex I…
Re: Replace eregi_replace expression with preg_replace
Programming
Web Development
7 Years Ago
by cereal
…;/font>'; echo eregi_replace($eregPattern, $replacement, $text); print PHP_EOL; echo
preg_replace
($pregPattern, $replacement, $text); print PHP_EOL; > I how do I… check
preg_replace
function is executed or not? From the [documentation:](http://php…
Re: Help with regular expression
Programming
Web Development
13 Years Ago
by SerjSagan
I got this: echo
preg_replace
("\&diff.+?=prev", "", $mystring); using this tool: [url]http://gskinner.com/RegExr/[/url] But that gives me this error: Warning:
preg_replace
() [function.preg-replace]: Delimiter must not be alphanumeric or backslash in /home/enhancement/www/www/index.htm on line 134
Re: Only replace own website url in text with HTML links
Programming
Web Development
12 Years Ago
by diafol
Use preg replace?
preg_replace() help
Programming
Web Development
11 Years Ago
by cjohnweb
…($v as $keyword => $url){ $content =
preg_replace
("/(?!=(?:<a [^>]*>))({$keyword})(?!(?:<\/a>))/si… errors (link 67 is the
preg_replace
() line above): > Warning:
preg_replace
() [function.preg-replace.html]: Unknown… on line 67 > > Warning:
preg_replace
() [function.preg-replace.html]: Unknown modifier '/' …
Bad words filter through txt file
Programming
Web Development
11 Years Ago
by ska_defender
… = array( 'b***', 'p***', 'c***' ); $count = 0; if($replace){ $text =
preg_replace
($patterns, $replaces, $text, -1, $count); } else { foreach($patterns as $pattern… myfile.php on line 60 > > Warning:
preg_replace
() [function.preg-replace]: Delimiter must not be alphanumeric or…
php preg_match vs preg_replace
Programming
Web Development
14 Years Ago
by shishtawitch
i have following in my database ------------------------------------------------------------------------------------ [code=text] <table><tr><td><img src="default.jpg" width="160" style="border:1px #87925d solid;padding:2px;"></td> <td valign="top"><a href="…
preg_replace() compilation failed... Help!
Programming
Web Development
13 Years Ago
by Arrorn
…>'; $i++; } echo '</td></table>'; return
preg_replace
($search, $replace, $string); } [/CODE] When I run this function on… the post it gives me this error. [CODE]Warning:
preg_replace
() [function.preg-replace]: Compilation failed: missing terminating ] for character class…
Help with Regular expressions changeing urls
Programming
Web Development
13 Years Ago
by kingofkya
[url]http://php.net/manual/en/function.preg-replace.php[/url] [url]http://phpro.org/tutorials/Introduction-to-PHP-Regex.html#1[/url] I have been reading up on php regular expressions. Honestly I don't get it. I think i need to use the above. Here is my problem I am reading a page via php-curl and sending it to a string variable. Now before I …
preg_replace() error
Programming
Web Development
11 Years Ago
by hwoarang69
….php"); exit(); } //check if user exists in database $managerID =
preg_replace
('#[^0-9#]i','',$_SESSION["id"]); //decype the id… == 0) { header("location: ../index.php"); exit(); } ?> Warning:
preg_replace
() [function.preg-replace]: Unknown modifier ']' in C:\xampp\htdocs\E…
Re: Add hyphen to file name and keep extensions
Programming
Web Development
12 Years Ago
by Sogo7
… these $replacements[0] = '-'; $replacements[1] = 'black'; $replacements[2] = 'slow'; echo
preg_replace
($patterns, $replacements, $string);
Re: Replacing 2 characters with with preg_replace
Programming
Web Development
16 Years Ago
by Walkere
…net/manual/en/function.preg-replace.php"]
preg_replace
()[/URL] like Fungus did with str_replace - sending…could use arrays to perform the desired function with
preg_replace
. [code] $string = "\"You're… wise,\" said the wise man."; $string =
preg_replace
(array("/'/", '/"/'), array("\'", '\"'),…
Re: Spoofed Form Security
Programming
Web Development
11 Years Ago
by Philippe.Lahaie
[
preg_replace
](http://php.net/manual/en/function.preg-replace.php)
Re: unable to create short codes
Programming
Web Development
8 Years Ago
by cereal
As I see it, this is replacing only the last shortcode. If the goal is to replace all the `[shortcode ...]` blocks with `Shortcode displayed`, then [`
preg_replace
()`](http://php.net/preg-replace) should work fine: $matches =
preg_replace
("/\[(.*?)\]/", "Shortcode displayed", $content); echo $matches;
Re: simple smile function
Programming
Web Development
12 Years Ago
by amear
… litil help in this code i want to use $shout =
preg_replace
($code,'<img src="smiles/'.$image.'" title="…;', $shout); instead of str_replace but i got this error warning:
preg_replace
() [function.preg-replace]: Delimiter must not be alphanumeric or backslash…
Re: Regular expressions and getting parameters from them
Programming
Web Development
12 Years Ago
by pritaeas
[CODE=text] %GETVALUE(\d+)% [/CODE] I suggest you have a look at [URL="http://php.net/manual/en/function.preg-replace-callback.php"]preg_replace_callback[/URL]. It will make this a lot easier.
Re: reg exp issue
Programming
Web Development
11 Years Ago
by NinjaMediaD
… solves bot issues. my final is : function format_serial($serial) { return
preg_replace
('/^(eu) ?([a-z\d].+)$/ie', 'strtoupper("$1 $2"…
Re: php search engine problems
Programming
Web Development
15 Years Ago
by cwarn23
… be in $4.[/QUOTE] When I was first making this
preg_replace
(), I was at first thinking that until I descovered that…
1
2
3
17
Next
Last
Search
Search
Forum Categories
Hardware/Software
Programming
Digital Media
Community Center
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Meet People
Forums
Top Members
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
SEO Backlink Checker
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2024 DaniWeb® LLC