jasonrogena / jasonrogena/php-excel-reader

function hyperlink doesn't resolve column

Open
#158 0 comments 0 reactions 0 assignees View on GitHub
auto-migrated Priority-Medium Type-Defect
Dominant language
PHP
Stars
1
Forks
0
PR merge metrics
No merged PRs in 30d

Description

```
What steps will reproduce the problem?
1. Try to get a hyperlink and ask for column "a". You will receive an error
that the index doesn't exists.

Issue is that the hyperlink function should resolve the column as well or
performs some additional check if it's a resolved column or a clear column.

Documentation doesn't reflect.

Solution is to add the following to line #384:

$col = $this->getCol($col);

.. and it will work. The (raw) and (type) functions have probably the same
issue.

Here is an easy fix how to make it even better:

$col = is_numeric($col)?$col:$this->getCol($col);

Which is a dual approach. Now the programmer can either give a numeric value or
a named value.

Hope that helps!

Thanks,

Andy

```

Original issue reported on code.google.com by `flyand...@gmail.com` on 31 Oct 2012 at 10:23

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at line 384 in the hyperlink function and inspect how the column argument is handled. Update the column handling so named and numeric columns work, then verify that hyperlink, raw, and type calls no longer reject a resolved column.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.