extract

Extracting context from a set point in the middle of an HTML file.

I have some HTML, and I'm extracting a snippet at a certain point (an inline image), but I'd like to show some context around this image. I'm using PHP, and I know that both Symfony and Wordpress provide functions for dealing with what happens when you chop up text in the middle of some HTML (it closes all open tags), but nothing for de...

how to extract formatted text content from PDF using Python

How can I extract the text content (not images) from a PDF while (roughly) maintaining the style and layout like Google Docs can? ...

How to extract ONLY the contents of the JDK installer

I just downloaded the Java SDK/JDK versions 5 and 6, and I just need the development tools (and some libraries) contained in the installation packages, I don't need to perform an installation and that's why I was only looking for a zip package at first (for Windows there is only an exe installation file), I only need to extract the conte...

php - extract array into global variables

The manual on "extract" shows you can extract an array like: extract(array('one'=>1,'two'=>2)); into $one,$two... But the extract function doesn't return the variables. Is there a way to 'globalize' these variables? Maybe not using extract, but a foreach loop? EDIT: (explanation about what I'm trying to achieve) I have an array co...

How do I move a Git branch out into its own repository?

I have a branch that I'd like to move into a separate Git repository, and ideally keep that branch's history in the process. So far I've been looking at git filter-branch, but I can't make out whether it can do what I want to do. How do I extract a Git branch out into its own repository? ...

How are self-extracting executables made?

There are many programs out there that will allow you to pack a few files together and generate an executable that has the necessary code to extract them. Somehow, those files are residing inside the executable. I am interested in doing the same thing; how is this done? FYI, I'm interested primarily in Windows .exe files, if it makes a ...

Separating ASCII text from binary content in a file

I have a file that has both ASCII text and binary content. I would like to extract the text without having to parse the binary content as the binary content is 180MB. Can I simply extract the text for further manipulation ... what would be the best way of going about it. The ASCII is at the very beginning of the file. ...

can we implement a php extract function in php with out using zend api

Extract function of php adds variables to the local scope of the calling function. How can we write our own php function extract which does the same? ...

extract specific folder in shell command using unzip

My backup.zip has the following structure. OverallFolder lots of files and subfolders inside i used this unzip backup.zip -d ~/public_html/demo so i end up with ~/public_html/demo/OverallFolder/my other files. How do i extract so that i end up with all my files INSIDE OverallFolder GOING DIRECTLY into ~public_html/demo? ~/publ...

Regex extract number for RewriteRule

For http://macintosh.local/clientname/102 I can get the numeric reference (3 digits) like this: RewriteRule ^[^/]+/([0-9]{3}+)/?$ album.php?ref=$1 [L] Now I want to get my reference in my SEO URL: http://macintosh.local/clientname/102-some-keywords ...

grep and sed command question

Hi there i have a truckload of files with sql commands in them, i have been asked to extract all database table names from the files How can I use grep and sed to parse the files and create a list of the unique table names in a text file ..one per line? the name names all seem to start with "db_" which is handy! what would be the best ...

How does one extract the name of a variable in a function that is called from another function in R?

My question is how to extract the name of a variable from a function that is called in another function in R? To illustrate, here is an example: a <- function(variable) { print(deparse(substitute(variable))) internala(substitute(variable)) } internala <- function(variableXX) { namex=deparse(substitute(variableXX)) ...

Extract a ZIP file programmatically by DotNetZip library?

I have a function that get a ZIP file and extract it to a directory (I use DotNetZip library.) public void ExtractFileToDirectory(string zipFileName, string outputDirectory) { ZipFile zip = ZipFile.Read(zipFileName); Directory.CreateDirectory(outputDirectory); zip.ExtractAll(outputDirectory,ExtractExistingFileAction.Overw...

web page: semi-transparent elements -> PNG

I have a web site that makes use of CSS box shadows. To make the web site look good in more browsers, I want to make use of semi-transparent PNGs instead. And to avoid having to redraw elements in a graphics program, I would like to know: Is there a way to extract semi-transparent elements from a web page and store them in semi...

How do you read a jpg creation date in Flash using AS3

I'm loading thumbnails repeatedly in a sequential order. 01.jpg 02.jpg etc. I need to know if they're failing to be produced. The only way I can think of is to read the creation time of the jpg, so I can verify that it's been updated. Anyone know the best way to read creation time in jpg in as3? I didn't see that in the headers by pars...

Extracting Cell Text into a Separate Excel Worksheet

I have several models that will need to be translated to other languages and I want to put all text strings on a separate tab so they are all together. I need a utility/tool to locate standalone and embedded text strings, move them to another tab, and replace the original text string with the cell reference to the new location. A bonus ...

How to extract fields from a text line that has no constant deliminator?

What is the best way to extract each field from each line where there is no clear separator (deliminator) between each field? Here is a sample of the lines I need to extract its fields: 3/3/2010 11:00:46 AM BASEMENT-IN 3/3/2010 11:04:04 AM 2, YaserAlNaqeb BASEMENT-OUT 3/3/2010 11:04:06 AM ...

Extract Text based on Character - Flex

I'm using an auto complete component and a labelFunction so that user have the ability to search by their name or id. Once the search is completed I'd like to extract the data to a query. The only problem is that I only need the name or id for the query not both, so I'd like to pull from just the id variable... Currently if the user ty...

open source video sound extractor

I wanna an open source library to extract audio from video file through program code. ...

Oracle xmltype extract function never deallocate/reclaim memory until session down

Hi, I'm using Oracle 9.2x to do some xmltype data manipulation. The table as simple as tabls(xml sys.xmltype), with like 10000 rows stored. Now I use a cursor to loop every row, then doing like table.xml.extract('//.../text()','...').getStringVal(); I notice the oracle instance and the uga/pga keep allocating memory per execution of...