Omniture API

Omniture API can be daunting, but little pointers will ease your mind.

Omniture’s developer site is at https://developer.omniture.com

Currently they provide you with 10,000 tokens per month. Some reports will require two or more tokens.

Site Catalyst API

https://developer.omniture.com/en_US/documentation/sitecatalyst-reporting/

Use GetStatus to check the report status without consuming a token count.

Data Warehouse API

https://developer.omniture.com/en_US/documentation/data-warehouse/

Administration API

https://developer.omniture.com/en_US/documentation/omniture-administration/

rsid
Report suite ID

Metrics
ReportSuite.GetAvailableMetrics will get you all the metrics available per rsid.

Elements
Not all elements for your account are listed unless you query the ReportSuite.GetAvailableElements for the rsid.

,

No Comments

PDF for Codeigniter

There is no default PDF library for Codeigniter.
Pick and choose what’s the best.
Anyone have a favorite?

fPDF
mPDF

mPDF with Codeigniter
PDF generation using dompdf
fpdf CIed

No Comments

Dump database structure

How do you get a full database structure from Microsoft SQL Server?

select * from INFORMATION_SCHEMA.COLUMNS

4990486658 5f851dcc47 300x300 Dump database structure

No Comments

How do you move certain files from yesterday to another directory?

How do you move certain files from yesterday to another directory?

In current directory:

find . -type f -atime -1 -exec mv {} /newdirectory/ \;

From "/olddirectory/":
find /olddirectory/ -type f -atime -1 -exec mv {} /newdirectory/ \;

No Comments

Show directory’s disk usage

du -sk * | sort -nr | more

No Comments

Use Postgresql for WordPress?

I would love to run WordPress on Postgresql database, simply because most of DBs I use are Postgresql-based.

Here’s what WordPress says about it. http://codex.wordpress.org/Using_Alternative_Databases

I’m sure there must be a way to make WordPress more portable to other databases. What’s your take on this?

No Comments

New framework for PHP?

I’ve been watching FuelPHP framework for sometime and they finally released v1.0.

If you are used to Codeigniter, you may not be all enthusiastic about how FuelPHP does things. It’s different and I’m willing to dig in deeper. It would be nice to see a chart of comparisons.

No Comments

Track shipments on iphone

Here’s a simple idea… get all tracking numbers, UPS, FedEx, or any other common carrier’s into your iphone. Have the iphone alert you when shipment status change.

Well.. looks like someone already thought of that. Trackthepack has an iphone that does this sort of thing.

http://trackthepack.com/

No Comments

Best CodeIgniter Editors

10 million years old question…

What is your PHP IDE editor? This question should be more specific to CodeIgniter.

So, what is your best CodeIgniter editor? For multi-platform? I’ve come up with below. Suggestions welcomed.

Multi-platform

  • Aptana
  • Dreamweaver
  • Eclipse
  • Komodo Edit
  • Netbeans
  • PHPStorm
  • Zend Studio

Mac only

  • BBEdit
  • Coda
  • SubEthaEdit
  • Smultron
  • Textmate
  • TextWranger

Windows only

  • EditPlus
  • Notepad++
  • PHPed
  • UltraEdit

4 Comments

Find first and last sunday

This is a nifty query that I can use on reporting, I’m sure there are other uses for it.


declare @year int
set @year =2011

-- First and Last Sunday by SqlServerCurry.com
select min(dates) as first_sunday,max(dates) as last_sunday from
(
select dateadd(day,number-1,DATEADD(year,@year-1900,0))
as dates from master..spt_values
where type='p' and number between 1 and
DATEDIFF(day,DATEADD(year,@year-1900,0),DATEADD(year,@year-1900+1,0))
) as t
where DATENAME(weekday,dates)='sunday'
group by DATEADD(month,datediff(month,0,dates),0)

Source: http://www.sqlservercurry.com/2011/02/sql-server-first-and-last-sunday-of.html

No Comments