budimir Posted January 19, 2008 Share Posted January 19, 2008 Hi, I'm trying to create a php script which would take the data from MySQL database, sort it and print it to labels for envelopes. Now, I'm having trouble with formatting the print and adjusting it for the labels. Could someone post a code where I could define the size of the paper, how many labels are on the page (rows and columns) and to define the size of the labels? I now, that somebody will tell me that I need to post more data about the labels, but my problem is that I have two different sizes of labels so I will need to adjust for them. Thanks. Quote Link to comment https://forums.phpfreaks.com/topic/86785-solved-printing-on-labels/ Share on other sites More sharing options...
revraz Posted January 19, 2008 Share Posted January 19, 2008 May want to use CSS for that. Quote Link to comment https://forums.phpfreaks.com/topic/86785-solved-printing-on-labels/#findComment-443588 Share on other sites More sharing options...
budimir Posted January 19, 2008 Author Share Posted January 19, 2008 I'm not good with CSS. :-[ Quote Link to comment https://forums.phpfreaks.com/topic/86785-solved-printing-on-labels/#findComment-443674 Share on other sites More sharing options...
revraz Posted January 19, 2008 Share Posted January 19, 2008 Plenty of sites to teach you. Quote Link to comment https://forums.phpfreaks.com/topic/86785-solved-printing-on-labels/#findComment-443703 Share on other sites More sharing options...
Barand Posted January 19, 2008 Share Posted January 19, 2008 You'll get more precise positioning with something like FPDF www.fpdf.org Quote Link to comment https://forums.phpfreaks.com/topic/86785-solved-printing-on-labels/#findComment-443708 Share on other sites More sharing options...
Barand Posted January 19, 2008 Share Posted January 19, 2008 There is even a labels script on that site http://www.fpdf.org/en/script/script29.php Quote Link to comment https://forums.phpfreaks.com/topic/86785-solved-printing-on-labels/#findComment-443724 Share on other sites More sharing options...
budimir Posted January 20, 2008 Author Share Posted January 20, 2008 There is even a labels script on that site http://www.fpdf.org/en/script/script29.php Thanks a lot Barand. Looking at this, I got an Idea how to do it through php, without outputing to PDF. Regards Quote Link to comment https://forums.phpfreaks.com/topic/86785-solved-printing-on-labels/#findComment-444210 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.