Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

AzharAbbas's avatar

LabelWriter 450 Laravel

I'm using Laravel 10 and i want to print label with Dymo LabelWriter 450 how can i do that ?

0 likes
8 replies
nexxai's avatar

You would need to find some kind of Dymo LabelWriter driver, integrate it into your app, and then send your print jobs to it.

Without more details, that's as much help as anyone will be able to provide you.

1 like
nexxai's avatar

@AzharAbbas Sorry, but I am not taking consulting clients right now. This is a support forum so please ask specific questions about the problem you're having, but do not expect people to do your work for you. Show what you've tried to do and why it doesn't work.

1 like
AzharAbbas's avatar

this is my label print code but it is not working properly I already attch printer to system but it show printer is connected

<title>Label Printing</title>
<script>
    if (typeof dymo.label.framework !== 'undefined') {
        console.log('DYMO Label Framework is available');
    } else {
        console.error('DYMO Label Framework is not available');
    }

    function printLabel() {
        if (typeof dymo.label.framework !== 'undefined') {

            var labelXml = '<?xml version="1.0" encoding="utf-8"?>' +
                '<DieCutLabel Version="8.0" Units="twips">' +
                '<PaperOrientation>Landscape</PaperOrientation>' +
                '<Id>Address</Id>' +
                '<PaperName>30324 1-7/16 in x 3-1/2 in</PaperName>' +
                '<DrawCommands>' +
                '<RoundRectangle X="0" Y="0" Width="1581" Height="793" Rx="270" Ry="270"/>' +
                '</DrawCommands>' +
                '<ObjectInfo>' +
                '<TextObject>' +
                '<Name>Text</Name>' +
                '<ForeColor Alpha="255" Red="0" Green="0" Blue="0"/>' +
                '<BackColor Alpha="0" Red="255" Green="255" Blue="255"/>' +
                '<LinkedObjectName></LinkedObjectName>' +
                '<Rotation>Rotation0</Rotation>' +
                '<IsMirrored>False</IsMirrored>' +
                '<IsVariable>False</IsVariable>' +
                '<Text>' +
                '<String>Order ID: {{ $repair->id }}</String>' +
                '<Font Family="Arial" Size="12" Bold="False" Italic="False" Underline="False" Strikeout="False"/>' +
                '</Text>' +
                '<HorizontalAlignment>Left</HorizontalAlignment>' +
                '<VerticalAlignment>Middle</VerticalAlignment>' +
                '<LeftMargin>0</LeftMargin>' +
                '<RightMargin>0</RightMargin>' +
                '<TopMargin>0</TopMargin>' +
                '<BottomMargin>0</BottomMargin>' +
                '<IsDrawTextOutlines>False</IsDrawTextOutlines>' +
                '<IsMultiline>False</IsMultiline>' +
                '<IsWordWrap>True</IsWordWrap>' +
                '<IsVertical>False</IsVertical>' +
                '<ShapeType>Rectangle</ShapeType>' +
                '</TextObject>' +
                '<Bounds X="331" Y="119" Width="2844" Height="1260"/> </ObjectInfo></DieCutLabel>';


            labelXml = labelXml.replace('{{ $repair->id }}', 'Order ID: ' + '{{ $repair->id }}');
            labelXml = labelXml.replace('{{ $repair->created_at->format('Y-m-d') }}', 'Order Date: ' +
                '{{ $repair->created_at->format('Y-m-d') }}');
            labelXml = labelXml.replace('{{ $repair->password }}', 'Password: "' + '{{ $repair->password }}' + '"');
            labelXml = labelXml.replace('{{ !empty($repair->authorization) ? 'Yes' : 'No' }}', 'Authorization: ' +
                '{{ !empty($repair->authorization) ? 'Yes' : 'No' }}');

            var printerName = 'DYMO LabelWriter 450';


            var label = dymo.label.framework.openLabelXml(labelXml);
            label.print(printerName);
        } else {
            console.error('DYMO Label Framework is not available');
        }
    }


    var printers = dymo.label.framework.getPrinters();
    console.log('Available Printers:', printers);
</script>
martinbean's avatar

@AzharAbbas No one can help with “not working properly”. Explain why it’s not “working properly”.

What actually happens? And what are you expecting to happen instead?

AzharAbbas's avatar

@martinbean I add already js for checking for connected printers but it show no printer is connected

martinbean's avatar

@AzharAbbas A CORS error has nothing to do with using a label writer.

Create a new thread for new questions, instead of replying to an entirely unrelated one that’s three months old.

Please or to participate in this conversation.